diff --git a/infer/qwen/spider_dk/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..d0b07027e305b20cfb7a88a8ca8a2919af59188b --- /dev/null +++ b/infer/qwen/spider_dk/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday LIKE \"2001-%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , highest FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year > 2013 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg_average FROM stadium EXCEPT SELECT T1.average FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.concert_name , T2.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.Year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_ID = T3.concert_ID WHERE T3.theme = 'Hey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT max(weight) FROM Pets WHERE birthdate = (SELECT birthdate FROM Pets ORDER BY age LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = \"F\" AND T1.Fname = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T2.pettype = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID NOT IN (SELECT PetID FROM Has_Pet WHERE PetType = \"kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID WHERE T2.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT DISTINCT Fname , Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Mammal\" EXCEPT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Fowl\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT petid , weight FROM pets WHERE birthdate > '2020'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE birthdate > \"2020\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , PetType FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , PetType FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.Fname , T2.Lname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Mammal\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.Fname , T1.Lname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM has_pet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T1.stuid = T3.stuid WHERE T3.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT petid FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = '2001'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.Continent , count(*) , T1.ContId FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT t1.continent , count(*) , t2.contid FROM continents AS t1 JOIN countries AS t2 ON t1.contid = t2.contid GROUP BY t2.contid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId WHERE T2.year < 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT maker FROM cars_data WHERE YEAR >= 2019 ORDER BY YEAR DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model_id ORDER BY T2.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T1.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId ORDER BY T1.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.Continent = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = (SELECT T3.Maker FROM car_makers AS T3 GROUP BY T3.Maker ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = (SELECT T3.Maker FROM car_makers AS T3 GROUP BY T3.Maker ORDER BY COUNT(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T1.Maker = \"Amc Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'AMC Hornet Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName LIKE \"%Japanese%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker IN (SELECT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.model WHERE T2.make = 'Japanese')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(mpg) FROM cars_data WHERE cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT Weight FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.Id FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.MakeId = T2.Id GROUP BY T1.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T2.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T2.CountryId HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country == T2.CountryID GROUP BY T1.Country HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Make FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3 GROUP BY T2.Make", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.model WHERE T1.fullname = 'Ford' AND T2.cylinders = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY max(mpg) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT accelerate , cylinders FROM cars_data GROUP BY cylinders ORDER BY max(accelerate) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , Cylinders FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.Model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.Id = t2.MakeId GROUP BY t2.Model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model GROUP BY T1.Model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data WHERE YEAR != (SELECT max(YEAR) FROM cars_data))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2019 AND YEAR <= 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T2.FullName FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T1.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.FullName = \"General Motors\" UNION SELECT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight > 3500 OR T1.MPG = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(accelerate) , cylinders FROM cars_data WHERE make = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Tesla\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"Toyota\" OR maker = \"Honda\" OR maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.Cylinders = 4 GROUP BY T1.Model ORDER BY AVG(Horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Model = T2.Id WHERE Horsepower > (SELECT min(Horsepower) FROM cars_data WHERE cylinders <= 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM cars_data AS T1 JOIN car_names AS T2 ON T1.id = T2.model WHERE Horsepower > 50 EXCEPT SELECT T1.makeid , T2.fullname FROM cars_data AS T1 JOIN car_names AS T2 ON T1.id = T2.model WHERE cylinders = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T1.Maker = 'Ford Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.MakeId WHERE T2.Weight < 3500 EXCEPT SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.MakeId WHERE T2.Weight >= 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT CountryId FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 AND T1.Maker >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId JOIN car_names AS T3 ON T2.Model = T3.Model WHERE T3.Model = 'tesla' GROUP BY T1.CountryID HAVING COUNT(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId JOIN car_names AS T3 ON T2.Model = T3.Model WHERE T3.Model = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Maker WHERE T1.year = 2019 GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T2.CountryName FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Maker WHERE T1.year = 2018 GROUP BY T1.CountryId HAVING T1.MPG = 4500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE Abbreviation = 'Jetblue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = 'Alton'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'ATA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' AND T1.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = 'Syracuse' AND T1.DestAirport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.uid WHERE T2.Abandonment = 'Jetblue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT T1.airline , count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abnovation = 'JetBlue' INTERSECT SELECT T1.city , T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'ASY' GROUP BY T1.airline", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY Airport\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T2.airline , count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\" GROUP BY T1.airline", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN airports AS T2 ON T1.AirportCode = T2.AirportCode GROUP BY T1.Airline ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"APG\" INTERSECT SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline GROUP BY T1.Airline HAVING sum(T2.FlightNo) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline GROUP BY T1.Airline HAVING sum(T2.FlightNo) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights JOIN airlines ON flights.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T2.FlightNo FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT DISTINCT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' OR T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Syracuse\" OR T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DISTINCT destairport , sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM DOCUMENTS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , document_description FROM documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM Documents WHERE Template_ID = (SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT count(*) FROM Documents GROUP BY Template_ID HAVING sum(Document_Name) = (SELECT", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID , count(*) FROM Documents GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , Template_ID FROM Documents GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_Effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Date_Effective_from , T1.Date_Effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T2.Template_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT document_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT template_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_Effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_Effective_from FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_Effective_from , date_Effective_to FROM Templates WHERE date_Effective_to - date_Effective_from >= (CURRENT_DATE - 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_Effective_from , date_Effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_Effective_from , count(*) FROM Templates GROUP BY date_Effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_Effective_from FROM Templates GROUP BY date_Effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(version_number) , max(date_Effective_from) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT version_number , date_effective_from , date_effective_to FROM Templates ORDER BY version_number ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_Effective_from , T1.date_Effective_to FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T1.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T1.Document_Name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T1.document_id , T2.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM documents AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_Effective_from , T1.date_Effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_Effective_from , T1.date_Effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_Effective_from FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_Effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_Effective_from , date_Effective_to FROM Templates EXCEPT SELECT T1.date_Effective_from , T1.date_Effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM ref_template_types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.template_type_code = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Description = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T2.winner_name , T1.match_num FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.winner_age FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.age , T2.match_num FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT winner_rank , loser_rank FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches UNION SELECT avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T1.ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id UNION SELECT max(T1.ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT winner_rank FROM matches UNION SELECT loser_rank FROM matches ORDER BY winner_rank + loser_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.winner_name , T1.winner_entry FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'yes' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY tours DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T1.player_id = T3.player_id ORDER BY T3.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T3.player_id = T1.player_id WHERE T2.year = 2016 AND T3.ranking_points = (SELECT max(ranking_points) FROM rankings WHERE tours = \"Australian Open\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T2.player_id = T3.player_id WHERE T1.year = 2000 AND T3.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T1.player_id , T2.minutes FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.winner_rank) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.rank_points , T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , COUNT(*) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , count(*) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.ranking FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age , T2.ranking_date LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = \"WTA Championships\" AND winner_hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\" AND T2.year = 2022", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.birth_date FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_OF_WORK DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID ORDER BY T1.Orchestra_ID ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID ORDER BY T1.Year_of_Founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE YEAR_of_Founded = (SELECT max(YEAR_of_Founded) FROM orchestra)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_of_founded < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_of_founded > 2003 GROUP BY record_company HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE RESULT = \"if_first_show\" AND 宗教 (名字) = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE IF_first_show = 'Y' AND Performance_ID = (SELECT Performance_ID FROM performance WHERE Official_ratings_(millions) = 1 AND Weekly_rank = 1 AND TYPE = \"first\" AND Date LIKE \"%Glebe%\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE result = \"first\" ) GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE TYPE != \"Non-first\" GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.cell_number , T1.last_name , T1.home_phone FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 AND T1.state = 'Indiana'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN Treatments AS T3 ON T3.professional_id = T1.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.first_name , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN Treatments AS T3 ON T3.professional_id = T1.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.professional_id = T3.professional_id WHERE T3.email_address = (SELECT T4.email_address FROM owners AS T3 JOIN treatments AS T4 ON T3.professional_id = T4.professional_id WHERE T4.cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT T1.first_name FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id EXCEPT SELECT T3.first_name FROM Dogs AS T3 JOIN Owners AS T4 ON T3.owner_id = T4.owner_id WHERE T3.name = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals EXCEPT SELECT T1.first_name FROM Professionals AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.name = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.role_code = T2.treatment_type_code JOIN dogs AS T3 ON T3.dog_id = T2.dog_id WHERE T3.gender = 'dog' EXCEPT SELECT T1.professional_id , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.role_code = T2.treatment_type_code JOIN dogs AS T3 ON T3.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.role_code , T1.first_name , T1.last_name , T1.home_phone FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type WHERE T2.charge_amount = (SELECT sum(charge_amount) FROM charges) ORDER BY T2.charge_amount LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type WHERE T2.charge_amount = (SELECT sum(charge_amount) FROM charges)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.abandoned_yn) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T3.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.first_name , T2.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T3.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code JOIN owners AS T3 ON T1.professional_id = T3.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM charges AS T1 JOIN treatments AS T2 ON T1.charge_type = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T4.size FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.weight FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T3.date_of_treatment FROM dogs AS T1 JOIN treatment_Types AS T2 ON T1.dog_id = T2.dog_id JOIN treatments AS T3 ON T3.dog_id = T1.dog_id WHERE T2.treatment_type_code = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T3.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.treatment_type_description = \"Rarest\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city LIKE \"%VA%\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments WHERE treatment_type_code = \"Treatment\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments WHERE treatment_type_code = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T3.dog_id = T2.treatment_type_code WHERE T3.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'yes' AND age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'yes' AND age < (SELECT avg(age) FROM dogs WHERE abandoned_yn = 'yes')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = '1' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE abandoned_yn = 1 );", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE abandoned_yn = 'yes' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments );", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charge_amount) FROM charges WHERE charge_type = 'VIP'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title , highest_position FROM song ORDER BY sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 3000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Name NOT IN (SELECT T3.Name FROM singer AS T3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 GROUP BY Citizenship HAVING COUNT(*) >= 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..a9e171c47667ec5dfd0764c46bd862f67bb2d68f --- /dev/null +++ b/infer/qwen/spider_dk/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.Stadium_ID , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.Stadium_ID = T2.Stadium_ID GROUP BY T2.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT max(attend) FROM stadium WHERE highest = (SELECT max(attend) FROM stadium WHERE highest != (SELECT max(attend) FROM concert))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT min(lowest) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE Stadium_ID NOT IN (SELECT T1.Stadium_ID FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID WHERE T2.Song_release_year = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T1.singer_id = T3.singer_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(T1.lowest) , min(T1.lowest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT max(T1.lowest) , min(T1.lowest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(T1.lowest) , min(T1.lowest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT max(T1.lowest) , min(T1.lowest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT min(weight) FROM Pets WHERE birthdate = (SELECT min(birthdate) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.Sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.Age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.Major , T1.Age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = PetID AND T2.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\" EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > '2020'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > '2020'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T3.PetID = T1.PetID WHERE T3.pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.PetID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.PetID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , T1.StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID GROUP BY T1.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.continent , T1.contid , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.contid = T2.continent GROUP BY T1.continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make IN (SELECT make FROM cars_data ORDER BY horsepower LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make FROM car_makers WHERE model FROM car_makers ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM car_names WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM car_names WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T2.year >= 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Year < 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T2.year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , COUNT(*) FROM car_makers AS T1 JOIN continents AS T2 ON T1.Country = T2.ContId GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country ID GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid GROUP BY t2.countryid ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.full_name FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"Amc Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'Mazda' AND model = 'Mazetta Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE countryname = \"Japan\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullName LIKE \"%Japanese care%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT maker , model FROM model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT maker , model FROM model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.countryname , T2.id FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE T2.maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.countryname , T2.countryid FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid GROUP BY T2.countryid HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT AVG(Weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , avg(year) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"European\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Make FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , make FROM cars_data WHERE cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT make FROM car_names WHERE model = (SELECT make FROM cars_data ORDER BY mpg DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "{\"sql\": \"SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t2.model FROM car_names AS t1 JOIN model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT DISTINCT model FROM model_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 2023 INTERSECT SELECT count(*) FROM cars_data WHERE YEAR = 2022", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 2023 OR YEAR = 2022", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM car_makers WHERE maker = 'American'}", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM car_makers WHERE maker = 'American'}", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" OR T1.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight >= 3000 AND Weight <= 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Accelerate) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Tesla\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(DISTINCT maker) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(DISTINCT maker) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = 'Ford' AND cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 GROUP BY model ORDER BY max(horsepower) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM car_names WHERE model NOT IN (SELECT model FROM cars_data ORDER BY horsepower LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM car_names WHERE model NOT IN (SELECT model FROM cars_data WHERE horsepower = (SELECT min(horsepower) FROM cars_data)) GROUP BY makeid HAVING count(*) < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.Maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T1.make = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries EXCEPT SELECT T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries EXCEPT SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T2.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T2.maker HAVING count(*) >= 2 INTERSECT SELECT T1.id , T2.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T2.maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.countryid , T2.countryname FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid GROUP BY T1.country HAVING count(*) > 3 UNION SELECT T1.countryid , T2.countryname FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid JOIN model_list AS T3 ON T1.id = T3.model WHERE T3.Model = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.countryid , T2.countryname FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid GROUP BY T1.country HAVING count(*) > 3 UNION SELECT countryid , countryname FROM countries WHERE countryname = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE Country = \"USA\" AND City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'Syracuse' INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Aline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE FlightNo LIKE \"Jetblue%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'ASY' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ASY Airport\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"AHD Airport\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen' JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Aberdeen\" JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T2.sourceairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.airportname = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.destairport WHERE T3.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Syracuse' OR T2.airportname = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' OR T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DISTINCT destairport FROM flights UNION SELECT DISTINCT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DISTINCT destairport FROM flights UNION SELECT DISTINCT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM Documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\" AND template_id = (SELECT id FROM Templates WHERE template_type_code = \"CV\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , template_id FROM Documents GROUP BY template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID , COUNT(*) FROM Documents GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.date_effective_from FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_from < date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_from < date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM_templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT version_number , date_effective_from , date_effective_to FROM Templates ORDER BY version_number ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T2.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from , T1.date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T2.date_effective_from , T2.date_effective_to , count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T2.date_effective_from , T2.date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T2.template_type_description FROM documents AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.birth_date - 1900 FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.birth_date - 1900 FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T1.birth_date - 1900 LIKE \"%30%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) , avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches UNION SELECT avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T2.ranking) FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id OR T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 UNION SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.ranking_points FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.rank_points FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open Tourney\" ORDER BY T2.winner_rank LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank LIMIT 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.first_name , T1.last_name ORDER BY max(T2.minutes) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , avg(T2.ranking) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT ranking_points , T1.first_name , T1.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.ranking_points) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_hand) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"WTA Championships\" AND T2.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.hand = \"left\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\" AND work_type = \"Conductor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\" AND work_as_conductor = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , count(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY year_of_founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded LIMIT 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT orchestra FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra EXCEPT SELECT T2.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded > 2003 GROUP BY record_company INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'Yes' AND name = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'Yes' AND T1.name = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 'Yes') GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 'No') GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = \"Indiana\" UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = \"Indiana\" UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T3.owner_id = T2.owner_id WHERE T3.first_name + T3.last_name > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals UNION SELECT first_name FROM owners WHERE first_name NOT IN (SELECT name FROM dogs WHERE gender = 'dog')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals UNION SELECT first_name FROM owners WHERE first_name NOT IN (SELECT name FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.dog_id NOT IN (SELECT dog_id FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals EXCEPT SELECT T1.professional_id , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T3.dog_id = T1.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.home_phone FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T2.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T2.treatment_type_code ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(T2.cost_of_treatment) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , T1.first_name , T1.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , T1.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_description FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.weight = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_description FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = \"Rare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN breeds AS T3 ON T1.breed_code = T3.breed_code WHERE T3.breed_name = \"Rare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments WHERE dog_id IN (SELECT dog_id FROM dogs WHERE date_arrived < date_departed)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments WHERE treatment_type_code = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(Dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.role_code) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"male\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.first_name , T1.last_name) FROM PROFESSIONALS AS T1 JOIN TREATMENTS AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'male'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM PROFESSIONALS WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = '1' AND age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = '1' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = '1' EXCEPT SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = '1' AND abandoned_yn = '0'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(DISTINCT owner_id) FROM owners EXCEPT SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id );", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE dog_id IN ( SELECT dog_id FROM dogs ) )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals WHERE role_code = 'Professional'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T2.breed_name , T3.size_description FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T1.size_code = T3.size_code WHERE T1.gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , Max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY Highest_Position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , MAX(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT name FROM singer WHERE singer_id NOT IN (SELECT singer_id FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945 GROUP BY Citizenship", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..9395ae89e0e28950d166aa07be01bda9dedd1d3c --- /dev/null +++ b/infer/qwen/spider_dk/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , Song_release_year FROM singer ORDER BY Birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT max(Highest) FROM stadium WHERE Stadium_ID NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT min(lowest) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_Name , T2.Theme , COUNT(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T2.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.Name , T1.Theme , COUNT(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T2.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id WHERE T1.year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T2.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id WHERE T1.year <= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN song AS T2 ON T1.singer_id = T2.singer_id WHERE T2.song_title LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(T1.Lowest) , min(T1.Lowest) , max(T1.Highest) , min(T1.Highest) FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T2.Year = 2014 INTERSECT SELECT max(T1.Lowest) , min(T1.Lowest) , max(T1.Highest) , min(T1.Highest) FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T2.Year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(T1.lowest) , min(T1.lowest) , max(T1.capacity) , min(T1.capacity) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT max(T1.lowest) , min(T1.lowest) , max(T1.capacity) , min(T1.capacity) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Sex = \"F\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT PetType) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"kitten\" OR T3.pettype = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT fname , age FROM Student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetType = \"dog\" EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE birthdate > \"2020\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > '2020'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.petid IN (SELECT petid FROM Pets WHERE pettype = \"Mammal\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.birthdate = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Students WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Students WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Continent = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = 'Ford' ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = 'Ford' ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT avg(weight) FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Year >= 2022 AND T2.Year <= 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Year < 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.Year FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId ORDER BY T1.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.Year FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T1.MakeId = T2.ModelId ORDER BY T1.Year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.MakeId WHERE T2.Year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.Mileage >= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , COUNT(*) FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Maker = \"Amc\" AND T2.Model = \"Hornet Sportabout (Sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE model = \"AMC Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'Japan'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.model WHERE T2.make = \"Japanese care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T2.Maker , T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T2.CountryId FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T2.CountryId HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T2.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T2.CountryId HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Maker FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Maker FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY sum(mpg) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Maker FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Make = \"Make\" GROUP BY T1.Make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM model_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 2023 INTERSECT SELECT count(*) FROM cars_data WHERE YEAR = 2022", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2023 AND YEAR < 2024", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = \"American Motor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname LIKE \"%American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker JOIN cars_data AS T3 ON T3.Id = T2.Model WHERE T1.FullName = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Model = \"General Motors\" UNION SELECT DISTINCT T2.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.MPG > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE Weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Accelerate) , Cylinders FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Tesla\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers WHERE maker LIKE '%more%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = (SELECT country FROM car_makers GROUP BY country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"Ford\" AND cylinders = 4 ORDER BY Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"4 Cylinder\" GROUP BY model ORDER BY max(horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM car_names WHERE id IN (SELECT id FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data)) EXCEPT SELECT makeid , make FROM car_names WHERE cylinders > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM car_names WHERE makeid NOT IN (SELECT makeid FROM cars_data WHERE horsepower = (SELECT min(horsepower) FROM cars_data)) AND cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T1.maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.id = T2.id WHERE T1.maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries EXCEPT SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Id HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'tesla' UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Makes = \"Tesla\" UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Makes = \"Car\" AND T2.Cylinders > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport LIKE 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = (SELECT airportcode FROM airports WHERE city = 'Jackson')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = (SELECT airportcode FROM airports WHERE city = 'Jackson')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.airportcode WHERE T2.city = 'Syracuse' AND T1.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Ashley\" AND T1.SourceAirport = \"Syracuse\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.Airline WHERE T2.Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE destairport IN (SELECT airportcode FROM airports WHERE airportname = \"Jetblue\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"JetBlue\" AND T1.SourceAirport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T2.SourceAirport ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT airline FROM flights GROUP BY airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT airline FROM flights GROUP BY airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline GROUP BY T1.Airline ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T2.Airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.DestAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = (SELECT airportcode FROM airports WHERE city = 'Jackson')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Syracuse\" OR T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Syracuse\" OR T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\" AND template_id = (SELECT * FROM Templates WHERE template_type_code = \"CV\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , template_id FROM Documents GROUP BY template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.date_effective_from FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT T1.template_id FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T2.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from , T1.date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM ref_template_types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM ref_template_types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.winner_age , T2.winner_age FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T2.winner_age , T1.match_num FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT loser_age , winner_age FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT T1.rank , T2.rank FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id UNION SELECT T1.rank , T2.rank FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) + avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) , max(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 OR T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 OR T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.winner_rank , T1.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.winner_rank_points = (SELECT max(winner_rank_points) FROM rankings AS T3 JOIN matches AS T4 ON T3.player_id = T4.winner_id WHERE T4.tourney_name = \"Australian Open\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id UNION SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T2.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.minutes = (SELECT max(minutes) FROM matches)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(ranking_points) , T1.first_name , T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name , T1.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.first_name , T1.last_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T2.winner_hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = 'left' AND T2.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE If_first_show = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T1.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , count(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY YEAR_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC LIMIT 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE YEAR_of_founded < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded > 2003 GROUP BY record_company HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1 AND RESULT = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1 AND RESULT = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id IN (SELECT performance_id FROM show WHERE if_first_show = 0 GROUP BY performance_id HAVING COUNT(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance EXCEPT SELECT TYPE FROM performance WHERE if_first_show = 1 GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM OWNERS INTERSECT SELECT state FROM PROFESSIONALS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 AND T1.state = \"Indiana\" UNION SELECT T1.professional_id , T1.first_name , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN owners AS T3 ON T1.zip_code = T3.zip_code WHERE T3.state = 'Indiana' OR count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals EXCEPT SELECT T1.first_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.role_code = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.dog_id = (SELECT dog_id FROM dogs WHERE gender = 'male') EXCEPT SELECT professional_id FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.cell_number FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.cell_number FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T3.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T3.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.cell_number FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN owners AS T3 ON T2.email_address = T3.email_address", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments JOIN treatment_types ON treatments.treatment_type_code = treatment_types.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , T1.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.size_description FROM Sizes AS T1 JOIN Dogs AS T2 ON T1.size_code = T2.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.size_code FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id ORDER BY T2.date_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id ORDER BY T2.date_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.date_arrived < date_departed", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = 'HI' OR state = 'WI'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs) AND abandoned_yn = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = '1' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = 'no' EXCEPT SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = 'yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN (SELECT owner_id FROM Dogs WHERE abandoned_yn = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments WHERE gender = 'dog')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM Charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT breed_name , size_description FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_code , T2.treatment_type_description FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Name NOT IN (SELECT T3.Name FROM song AS T3 JOIN singer AS T4 ON T3.Singer_ID = T4.Singer_ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..a8452eeb91fcd202e492fea340fc5ed3d51f900f --- /dev/null +++ b/infer/qwen/spider_dk/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , highest FROM stadium GROUP BY highest ORDER BY highest DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY highest LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T3.name , T3.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id JOIN singer_in_concert AS T3 ON T1.concert_id = T3.concert_id WHERE T1.year > 2013 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE stadium_id NOT IN (SELECT T1.stadium_id FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id WHERE T1.year = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT lowest FROM stadium EXCEPT SELECT T1.lowest FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.Name , COUNT(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID GROUP BY T3.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T2.name , T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T3.lighest , T3.lowest FROM concert AS T1 JOIN singer AS T2 ON T1.concert_id = T2.concert_id JOIN stadium AS T3 ON T3.stadium_id = T1.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T3.lighest , T3.lowest FROM concert AS T1 JOIN singer AS T2 ON T1.concert_id = T2.concert_id JOIN stadium AS T3 ON T3.stadium_id = T1.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT T1.concert_id FROM concert AS T1 JOIN singer AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T1.Fname != \"unknown\" AND T1.lname != \"unknown\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T2.fname , T2.lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T2.fname , T2.lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.StuID = T2.PetID WHERE T2.PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID NOT IN (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate < '2020'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > '2020-' , '01-01'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.PetID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT petid FROM Has_pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Fname , T2.Sex FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.birthdate = \"2001-01-01\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.aker WHERE T2.year >= 2020 UNION SELECT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.aker WHERE T2.year >= 2021", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE T2.year < 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid ORDER BY T2.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T1.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid ORDER BY T1.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.modelid = T2.model WHERE T2.year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T2.Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T4.Accelerate FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker JOIN car_names AS T3 ON T2.Model = T3.Model JOIN cars_data AS T4 ON T3.Make = T4.MakeId WHERE T1.Maker = \"Amc hornet sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"AMC Hornet Sportabout\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"Japanese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T1.Maker = \"Japanese care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullname = 'Ford' AND T2.model = 'Fordster']", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T2.CountryName , T1.id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id GROUP BY T1.CountryId HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.Continent = \"Europe\" GROUP BY T1.Country > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryID WHERE T1.Maker = \"Ford\" GROUP BY T1.Maker HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T1.Horsepower) , T1.MakeId FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3 GROUP BY T1.MakeId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T1.Maker FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.Cylinders = 3 GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.Model FROM car_names AS t1 JOIN model_list AS t2 ON t1.Model = t2.Modelid JOIN car_makers AS t3 ON t2.Maker = t3.Id GROUP BY t2.Model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM cars_data WHERE YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data WHERE YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(YEAR) FROM cars_data) AND YEAR = (SELECT max(Y", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2019 AND YEAR <= 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(DISTINCT t1.model) FROM model_list AS t1 JOIN car_makers AS t2 ON t1.maker = t2.id JOIN cars_data AS t3 ON t3.id = t1.model WHERE t2.fullname = \"American Motor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.aker WHERE T1.fullname = 'American Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" OR T1.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T1.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Cylinders) FROM cars_data WHERE Make = \"Tesla\" AND Accelerate = (SELECT min(Accelerate) FROM cars_data WHERE Make = \"Tesla\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Tesla\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = (SELECT country FROM countries GROUP BY country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 GROUP BY model ORDER BY max(horsepower) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM car_names WHERE makeid NOT IN (SELECT makeid FROM cars_data ORDER BY horsepower LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM cars_data WHERE horsepower != 200 GROUP BY makeid HAVING count(*) < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T1.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T2.maker = 'Ford Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT model FROM car_names WHERE make = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model GROUP BY T1.Id HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM cars_data AS T1 JOIN countries AS T2 ON T1.Id = T2.Id JOIN car_makers AS T3 ON T3.Id = T1.Id WHERE T3.Maker = 'Tesla' UNION SELECT T4.CountryId , T5.CountryName FROM cars_data AS T1 JOIN car_names AS T2 ON T2.Model = T1.Model JOIN countries AS T3 ON T3.MakeId = T2.MakeId WHERE T2.Model = 'Tesla' GROUP BY T4.CountryId HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING count(*) > 3 UNION SELECT CountryId , CountryName FROM countries AS T2 JOIN car_makers AS T1 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = 'Syracuse' AND T1.DestAirport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Ashley\" AND T1.SourceAirport = \"Syracuse\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.Airline WHERE T2.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceAirport = T2.airportCode WHERE T2.airportname = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'ASY' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"AHD\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"AHD Airport\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.Airline , T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.destairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T2.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T2.Airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN airports AS T2 ON T1.Abbreviation = T2.airportcode GROUP BY T1.Abbreviation ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.abbreviation = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T1.Airline = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T1.Airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT DISTINCT airline FROM flights GROUP BY airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT DISTINCT airline FROM flights GROUP BY airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT DISTINCT airline FROM flights GROUP BY airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID HAVING sum(T1.UID) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"JETBLU\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.AirportCode = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Syracuse\" OR T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights OR sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , document_description FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE Template_ID = (SELECT T1.Template_ID FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T2.template_type_description = \"PPT\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID , count(*) FROM Documents GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID , COUNT(*) FROM Documents GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.date_effective_from FROM templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM DOCUMENTS AS T1 JOIN MOURES AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT T1.template_id FROM DOCUMENTS AS T1 JOIN PARAGRAPHS AS T2 ON T1.template_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT document_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT document_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_from < date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_to - date_effective_from > 14 days", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(version_number) , min(date_effective_from) , min(date_effective_to) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T1.document_id , T2.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.date_effective_from , count(*) FROM Templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.template_type_code = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = (SELECT template_type_code FROM Ref_Template_Types WHERE template_type_Description = \"Presentation\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE Template_Details = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.winner_age FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.winner_age FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) , avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) , avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T1.ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id UNION SELECT max(T1.ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id UNION SELECT max(ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id UNION SELECT T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.loser_id = T1.player_id WHERE T3.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id WHERE T3.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id UNION SELECT T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.loser_id = T1.player_id WHERE T3.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id WHERE T3.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T2.player_id = T3.player_id WHERE T1.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.first_name , T1.last_name ORDER BY T2.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T1.player_id , T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.round , T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.first_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.Name , T1.Orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID ORDER BY T1.Year_of_Founded LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , count(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT T2.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.Year_of_Founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE Performance_ID IN (SELECT Performance_ID FROM performance WHERE Performance = \"Glebe Park\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE IF_first_show = 1 AND Performance_ID IN (SELECT Performance_ID FROM performance WHERE Official_ratings_(_) = \"Glebe Park\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id IN (SELECT Performance_ID FROM show WHERE If_first_show = 'No' GROUP BY Performance_ID HAVING COUNT(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 'Y') GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT cell_number , last_name FROM Professionals WHERE state = \"Indiana\" UNION SELECT T1.cell_number , T1.last_name FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.professional_id GROUP BY T1.cell_number HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT DISTINCT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\" OR count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T3.owner_id = T2.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals UNION SELECT first_name FROM owners EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals EXCEPT SELECT T1.first_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE name IN (\"dog name\", \"dog owner\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.home_phone FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T2.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T2.breed_name ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T3.dog_id = T2.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T2.treatment_type_code ORDER BY sum(T2.charge_amount) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN owners AS T2 ON T1.treatment_type_code = T2.owner_id WHERE T1.treatment_type_code = (SELECT treatment_type_code FROM treatments GROUP BY treatment_type_code ORDER BY sum(cost_of_treatment) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.weight FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.weight FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.gender = 'dog' AND T2.treatment_type_code = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id ORDER BY T2.date_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments WHERE treatment_type_code = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.professional_id) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"Veterinary\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = 'y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = 'y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(Dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE abandoned_yn = '1' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE dog_id = \"dog\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charge_amount) FROM charges WHERE charge_type = 'Monthly'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.role_code , T3.first_name , T3.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , MAX(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Name NOT IN (SELECT T3.Singer_ID FROM song AS T3 ON T3.Singer_ID = T2.Singer_ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..4f0684609f6d4d3e2b8912f649da2eb62b95dd7d --- /dev/null +++ b/infer/qwen/spider_dk/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT Name , Country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.Song_release_year FROM singer AS T1 JOIN singer_in_concent as T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T2.concent YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT T1.name , T1.song_release_year FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.singer_id = T2.singer_id ORDER BY T2.concent YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Birthday = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Birthday = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , COUNT(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE singer_id IN (SELECT singer_id FROM singer_in_concert GROUP BY singer_id HAVING avg(birthday) > (SELECT avg(birthday) FROM singer))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE singer_id IN (SELECT singer_id FROM singer_in_concert WHERE YEAR = (SELECT avg(YEAR) FROM concert))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.concentor_id , count(*) FROM concert AS T1 JOIN singer_in_concentor AS T2 ON T1.concentor_id = T2.concentor_id GROUP BY T1.concentor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.max_attendance FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY T2.max_attendance DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY year DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT max(Attendance) FROM concert WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT min(T1.atendance) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.theme = \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert WHERE Year = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT min(T2.attendance) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 EXCEPT SELECT min(attendance) FROM stadium WHERE T1.stadium_id NOT IN (SELECT stadium_id FROM concert WHERE year = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.name , T1.theme , count(*) FROM singer AS T1 JOIN singer_in_concentment AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.name , T2.theme , count(*) FROM singer AS T1 JOIN singer_in_concent as T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM singer_in_concent T1 JOIN singer T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concentment AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id WHERE T1.year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.concent.YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T2.Name , T2.Country FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.song_name = \"Hey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T2.Name , T2.Country FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Song_Name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT min(T1.attendance) , max(T1.attendance) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT min(T1.attendance) , max(T1.attendance) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT min(Average) , max(Average) FROM concert AS T1 JOIN stadium AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T1.Year = 2014 INTERSECT SELECT min(Average) , max(Average) FROM concert AS T1 JOIN stadium AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T1.Year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM concert ORDER BY capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM concert ORDER BY capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Has_pet WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Has_pem WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT T2.weight FROM Has_pem T1 JOIN Pets T2 ON T1.petid = T2.petid JOIN Student T3 ON T1.stuid = T3.stuid WHERE T3.age = (SELECT min(age) FROM student) AND T3.sex = \"F\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT sum(weight) FROM Has_pem WHERE petid = 2 AND birthdate = (SELECT min(birthdate) FROM Pets WHERE pettype = 'dog')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Has_pet GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Has_pet GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T1.Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_ppet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.sex = \"F\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_pupus AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Has_pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM has_pemet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'Kitten' OR T3.pettype = 'Pupus'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T2.Fname FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T2.pettype = 'Pug' OR T2.pettype = 'Kittens'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'Puppy' INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'Kittens'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T2.Fname FROM Has_pem T1 JOIN Student T2 ON T1.StuID = T2.StuID JOIN Pets T3 ON T1.PetID = T3.PetID WHERE T3.pettype = 'kitten' INTERSECT SELECT T2.Fname FROM Has_pem T1 JOIN Student T2 ON T1.StuID = T2.StuID JOIN Pets T3 ON T1.PetID = T3.PetID WHERE T3.pettype = 'puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T2.Major , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID != (SELECT T3.PetID FROM Has_Pet AS T3 JOIN Pets AS T4 ON T3.PetID = T4.PetID WHERE T4.PetType = 'Kittens')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = 'kittens'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.petID = 1 EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.petID = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Fname FROM Student WHERE StuID IN (SELECT StuID FROM Has_pod WHERE PetID = 1 EXCEPT SELECT StuID FROM Has_pet WHERE PetID = 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , sum(weight) FROM Has_pemus AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid GROUP BY T1.petid ORDER BY T1.birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT T2.petid , T2.weight FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T1.stuid = (SELECT stuid FROM Has_pet WHERE birthdate = '2020' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT StuID , weight FROM Has_pet WHERE birthdate > '2020'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(T1.pettype) , max(T1.pettype) FROM has_pet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid GROUP BY T1.pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(T2.pettype) , max(T2.pettype) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid GROUP BY T2.pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetType) , max(PetType) FROM Has_pet GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Has_pet GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age , T2.lname FROM Has_pemet AS T1 JOIN Student AS T2 ON T1.stuID = T2.stuID WHERE T1.pemetID = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT StuID FROM Has_pem WHERE StuID IN (SELECT StuID FROM Has_pem WHERE PetID IN (SELECT PetID FROM Pets WHERE T1.LName = 'Smith'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.StuID FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , T1.stuID FROM Has_pet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid GROUP BY T1.stuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Fname , T2.Sex FROM Has_pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pemet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.birthdate = \"2001\" AND T3.pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_pem T1 JOIN Student T2 ON T1.StuID = T2.StuID JOIN Pets T3 ON T3.PetID = T1.PetID WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student EXCEPT SELECT avg(stuID) FROM Has_pemet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(T1.age) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT avg(age) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM countries WHERE countryname = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT continent_id , continent_name , count(*) FROM countries GROUP BY continent_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT continent , countryname , count(*) FROM countries GROUP BY countryname", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT maker , count(*) , maker , fullname FROM car_makers GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT maker , maker , count(*) FROM car_makers GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE horsepower = (SELECT min(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN cars_data AS T3 ON T3.Id = T2.Model ORDER BY T3.Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_makers AS T3 ON T2.Model = T3.Model WHERE T3.Weight < (SELECT avg(T1.Weight) FROM cars_data AS T1 WHERE T1.Id = T3.Id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_makers AS T3 ON T2.Model = T3.Model WHERE T3.Weight < (SELECT avg(T1.Weight) FROM cars_data AS T1 WHERE T1.Id = T3.Id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT maker FROM car_makers WHERE YEAR BETWEEN 2 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT maker FROM car_makers WHERE YEAR BETWEEN 2 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT maker , YEAR FROM cars_data ORDER BY YEAR ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT maker , YEAR FROM cars_data ORDER BY YEAR ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_makers AS T3 ON T2.Model = T3.Model WHERE T3.Maker = T2.Make AND T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT maker FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT continent , count(*) FROM country AS t1 JOIN continents AS t2 ON t1.Continent = t2.Continent GROUP BY t1.CountryName", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT continent , count(*) FROM country AS T1 JOIN continents AS T2 ON T1 Continent = T2.ContId GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country_name FROM car_makers GROUP BY country_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country FROM car_makers GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , t1.FFullName FROM car_makers AS t1 JOIN car_names AS t2 ON t1.Id = t2.MakeId GROUP BY t1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , maker , maker_name FROM car_makers GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE YEAR = 2012 AND MAKING = \"Amc hornet sportabout\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "{\"sql\": \"SELECT accelerate FROM cars_data WHERE country = 'America' AND id = 2000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country_name = \"Japanese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN country AS T3 ON T1.CountryId = T3.CountryId WHERE T3.CountryName = \"Japanese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN cars_data AS T3 ON T3.id = T2.model WHERE T3.country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN country AS T2 ON T1.country_id = T2.country_id JOIN continents AS T3 ON T2 Continent = T3.Continent WHERE T3.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MGPH) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MGPH) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND Cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT maker , model FROM car_makers", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT maker , model FROM car_makers", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT maker , country FROM car_makers GROUP BY country HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT countryname , countryid FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(Weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(T1.Weight) , T1.Year FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id JOIN countries AS T3 ON T2.CountryId = T3.CountryId GROUP BY T1.Year", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid WHERE countryname = \"Europe\" GROUP BY countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT countryname FROM countries WHERE countryname LIKE '%Europe%' GROUP BY countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T3.Mark FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.MakeId JOIN car_makers AS T3 ON T2.Model = T3.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Make FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.MakeId JOIN model_list AS T3 ON T1.Model = T3.Model WHERE T3.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT maker FROM car_makers JOIN car_names AS T1 ON T1.MakeId = T1.MakeID JOIN model_list AS T2 ON T2.Model = T1.Model WHERE T2.Maker = \"Ford\" GROUP BY T2.Make ORDER BY AVG(MGPH) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN cars_data AS T3 ON T2.Model = T3.Model ORDER BY T3.MGPS DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE maker = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE maker = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , count(*) FROM cars_data WHERE cylinders = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) FROM cars_data WHERE cylinders = \"1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT DISTINCT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR BETWEEN 2010 AND 2012", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR BETWEEN 2015 AND 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN countries AS T3 ON T3.countryid = T1.country WHERE T3.countryname = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN country AS T2 ON T1.countryid = T2.countryid WHERE countryname = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , fullname FROM car_makers WHERE id NOT IN (SELECT maker FROM car_makers GROUP BY maker HAVING count(*) > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , id FROM car_makers GROUP BY maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN cars_data AS T3 ON T3.Id = T2.Model WHERE T1.Maker = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN cars_data AS T3 ON T3.id = T2.id JOIN car_makers AS T4 ON T4.id = T2.id JOIN car_makes AS T5 ON T4.id = T5.id WHERE T5.maker = \"General Motors\" OR T3.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE WEIGHT < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE WEIGHT > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT accelerate FROM cars_data WHERE id = 1 GROUP BY accelerator ORDER BY min(accelerate) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "{\"sql\": \"SELECT COUNT(*) FROM cars_data WHERE accelerator_time = (SELECT min(acceleration_time) FROM cars_data WHERE maker = \\\"Tesla\")\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE acceleration > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country != \"United States\" GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE countryId NOT IN (SELECT countryId FROM countries GROUP BY countryId HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Cylinders = 4 GROUP BY T1.Model ORDER BY T1.Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN cars_data AS T3 ON T2.Model = T3.Model WHERE T3.Cylinders = 4 GROUP BY T1.Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT maker , maker_name FROM car_makers WHERE id NOT IN (SELECT id FROM cars_data WHERE horsepower < 3) GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT DISTINCT T1.Make , T1.FFullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Maker != \"United States\" AND T1.Cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MGPH) , id FROM cars_data WHERE Cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MGPS) FROM cars_data WHERE Cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE weight < 3500 EXCEPT SELECT maker FROM car_makers WHERE maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE weight < 3500 AND maker != \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT countryid FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT countryid FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , maker FROM car_makers GROUP BY maker HAVING count(*) >= 2 INTERSECT SELECT maker FROM car_makes GROUP BY maker HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT id , maker FROM car_makers WHERE maker = (SELECT maker FROM car_makers GROUP BY maker HAVING count(*) >= 2) INTERSECT SELECT id , maker FROM car_makers GROUP BY maker HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT countryid , countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid GROUP BY T1.countryid HAVING count(*) > 3 OR T2.FName = 'tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT countryid , countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid GROUP BY T1.countryid HAVING count(*) > 3 OR T2.FFullName = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE airline = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airline , abbreviation FROM airlines WHERE country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airline , Abbreviation FROM airlines WHERE Country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"JASON\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Syrct\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT T1.City , T1.Country FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.FlightNo = 'Alton Airport'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE AirportName = 'Alton'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = 'ATA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Syracuse\" AND destairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Syrus' AND destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE airline = \"JETBLER\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"JetBlue\" AND flightno = \"ASY\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"JSTJ\" AND FlightNo = \"JETBELE\" AND DestAirport = \"ASY Airport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM flights WHERE airline = 'JST' AND FlightNo = 'JST-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000-10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'Abberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"JetBlue\" AND sourceairport = \"Aberona\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.City FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode JOIN airlines AS T3 ON T1.Airline = T3.Airline WHERE T3.Airline = 'South East Asia' GROUP BY T2.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.City FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode JOIN airports AS T3 ON T1.DestAirport = T3.AirportCode GROUP BY T3.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport ORDER BY T2.sourceairport DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.sourceairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT airportcode FROM airports GROUP BY airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT airline FROM flights GROUP BY airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT airline FROM flights GROUP BY airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT avg(T1.FlightNo) , T1.AbbrCode FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline GROUP BY T1.AbbrCode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Ababbrev, T2.country FROM airlines AS T1 JOIN airports AS T2 ON T1.airportcode = T2.airportcode GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airleigh = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T2.airlines FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T1.airline = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T2.airline FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T1.city = T3.city WHERE T3.airportname = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T2.airline FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.airline WHERE T2.city = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.sourceairport = 'APG' INTERSECT SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.destairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.sourceairport = 'APG' INTERSECT SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.destairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airname FROM airlines AS T1 JOIN airports AS T2 ON T1.airpointcode = T2.airportcode WHERE T2.airportname = 'CVO' EXCEPT SELECT T1.airname FROM airlines AS T1 JOIN airports AS T2 ON T1.airpointcode = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT airline FROM flights WHERE sourceairport = 'CVO' EXCEPT SELECT airline FROM airlines WHERE airportcode = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = 'JETBELOG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE AirportCode = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE AirportCode = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE AirportCode = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Syratay\" OR destairport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM airports WHERE airportname = \"Syrus\" OR airportcode = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DISTINCT DostAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DISTINCT DstAirport FROM flights) UNION SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DISTINCT SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T2.Document_Name FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Details LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T2.document_name , T1.document_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T1.document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_name , document_description FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT T1.document_name , T1.document_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.date_effective_from = 'Robbin CV'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT t1.template_details) FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT t1.template_details) FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE document_id IN (SELECT document_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT T1.template_id , count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT T1.Template_Type_Code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T2.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.Template_ID FROM templates AS T1 JOIN documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T2.Template_ID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.Template_ID FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT document_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code NOT IN (SELECT template_type_code FROM documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT effective_date_period , template_type_code FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT effective_date_period , template_type_code FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_to FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT effective_date_from FROM templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT effective_date_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT effective_date_from , template_type_code FROM templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT effective_date_period , template_type_code FROM templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT effective_date_period , count(*) FROM Templates GROUP BY effective_date_period", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT effective_date_from FROM Templates GROUP BY effective_date_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT effective_date_from FROM templates GROUP BY effective_date_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM templates WHERE date_effective_from - date_effective_to < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT effective_date_period FROM Templates GROUP BY effective_date_period HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , effective_to FROM Templates ORDER BY effective_to - effective_from ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , date_effected_from , date_effected_to FROM templates ORDER BY effective_from - effective_to ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT date_effective_from FROM templates WHERE document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T2.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.date_effective_from = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name , document_id FROM Documents WHERE template_id IN (SELECT template_id FROM Templates WHERE template_type_code = \"BK\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT t1.document_name FROM documents AS t1 JOIN templates AS t2 ON t1.template_id = t2.template_id WHERE t2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_to - date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT effective_date_from , effective_date_to , count(*) FROM templates GROUP BY effective_date_to - effective_date_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT effective_date_from FROM Templates GROUP BY effective_date_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT effective_date_period FROM Templates GROUP BY effective_date_period ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT effective_date FROM Templates WHERE effective_date BETWEEN \"NULL\" AND \"NULL\" AND document_id NOT IN (SELECT document_id FROM Documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT effective_date_from , effective_date_to FROM templates WHERE effective_date_to != (SELECT effective_date_to FROM templates)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT DISTINCT template_type_code , template_type_description FROM Ref_template_types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t2.template_type_description FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT T2.Template_Type_Description FROM Ref_template_types AS T1 JOIN templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.template_type_code FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM ref_template_types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM ref_template_types AS t1 JOIN documents AS t2 ON t1.template_type_code = t2.template_id JOIN templates AS t3 ON t2.template_id = t3.document_id WHERE t3.date_effective_to = '1' AND t3.date_effective_from = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.Template_Details FROM templates AS t1 JOIN documents AS t2 ON t1.Template_ID = t2.Template_ID GROUP BY t2.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_to FROM templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.player_name , T2.match_num FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.age , T2.match_num FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.age , T2.match_num FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT T1.name , T2.rank_points , T2.winner_rank, T2.loser_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(loser_rank) FROM matches WHERE winner_id = 1 OR loser_id = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(win_result) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tournament_id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.name , T2.name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date IN (SELECT birth_date FROM players ORDER BY birth_date ASC)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name FROM players WHERE hand = \"left\" ORDER BY birth_date;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T2.loser_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.match_num FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY sum(T2.rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"Australian Open tourney\" AND T2.winner_name = \"Winner\" ORDER BY T2.rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"Australian Open\" AND T2.winner_rank_points = (SELECT max(win_rank_points) FROM matches WHERE tourney_name = \"Australian Open\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T2.wider_result FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.wider_id GROUP BY T2.wider_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T2.loser_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T2.loser_id ORDER BY max(T2.match_num) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(leader_rank) , first_name FROM players GROUP BY first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.rank) , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT ranking_points , T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.first_name , T1.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.rank_points) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.first_name , T1.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT sum(tourney_rank) , T1.ranking_date FROM rankings AS T1 JOIN tours AS T2 ON T1.tourney_id = T2.tourney_id GROUP BY T1.ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT T1.tourney_name , COUNT(*) FROM rankings AS T1 JOIN teams AS T2 ON T1.tourney_id = T2.tourney_id GROUP BY T1.tourney_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , COUNT(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , COUNT(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.name , T1.rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.match_num LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.name , T1.rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.earliest DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT winner_id) FROM matches WHERE tourney_name = \"WTA Championships\" AND hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T1.hand = \"Left\" AND T2.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.wider_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE IF_first_show = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE IF_first_show = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Orchestra FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = \"Yes\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show != 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.conductor_id FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchite_id = T2.orchite_id JOIN conductor AS T3 ON T1.conductor_id = T3.conductor_id WHERE T2.type = \"Conductor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM conductor AS t1 JOIN orchestra AS t2 ON t1.conductor_id = t2.conductor_id GROUP BY t2.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.conductor_id ORDER BY YEAR_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.Orchestra = (SELECT T3.Orchestra FROM orchestra AS T3 WHERE T3.Year_of_Founded = (SELECT T4.Year_of_Founded FROM orchestra AS T4 WHERE T4.Major_Record_Format = 'Orchestial'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT orchestra , COUNT(*) FROM orchestra GROUP BY orchestra", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , count(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Conductor_ID ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT orchestra FROM performance ORDER BY share DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT orchestra FROM orchestra ORDER BY year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra EXCEPT SELECT orchestra FROM performance", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra EXCEPT SELECT orchestra FROM performance", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT orchestra FROM orchestra WHERE year_of_founder <= 2003 GROUP BY orchestra", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003 GROUP BY Record_Company HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show AS T1 JOIN performance AS T2 ON T1.Performing_ID = T2.Performing_ID WHERE T1.If_first_show = 'Glebe Park'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show AS T1 JOIN performance AS T2 ON T1.Performment_ID = T2.Performment_ID WHERE T1.If_first_show = 'Glebe Park'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE IF_first_show != 0 GROUP BY TYPE HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE IF_first_show != 1 GROUP BY TYPE HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT T2.state FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.role_code = 'PROFESSOR' INTERSECT SELECT T2.state FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.role_code = 'OWNER'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT T2.state FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.role_code = 'PROFESSOR' INTERSECT SELECT T2.state FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.role_code = 'OWNER'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Treatment\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE treatment_type_code = \"Treatment\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T2.professional_id , T2.last_name , T2.cell_phone FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.profession_id = T2.profession_id WHERE T1.date_of_treatment > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT DISTINCT T1.id , T1.last_name , T1.cell_phone FROM professionals AS T1 JOIN treatments AS T2 ON T1.profession_id = T2.profession_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.state = \"Indiana\" OR T2.treatment_type_code = \"2\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE cost_of_treatment <= 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM PROFESSIONS UNION SELECT first_name FROM OWNERS WHERE first_name NOT IN (SELECT first_name FROM PROFESSIONS) AND role_code = 'PROFESSIONAL' AND first_name != (SELECT first_name FROM PROFESSIONS WHERE role_code = 'PROFESSIONAL' AND first_name != (SELECT first_name FROM OWNERS WHERE role_code = 'PROFESSIONAL'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals EXCEPT SELECT T1.first_name FROM professionals AS T1 JOIN dogs AS T2 ON T1.profession_id = T2.profession_id WHERE T2.name LIKE \"%dog%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name FROM professionals EXCEPT SELECT T1.professional_id , T1.first_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.profession_id = T2.profession_id WHERE T2.dog_id = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id FROM professionals EXCEPT SELECT treatment_id FROM treatments WHERE dog_id IN (SELECT dog_id FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.weight = (SELECT max(weight) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , T2.city , T2.phone_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id GROUP BY T1.profession_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.date_of_treatment FROM Treatments AS T1 JOIN PROFESSIONS AS T2 ON T1.professional_id = T2.profession_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM Breeds WHERE breed_code = (SELECT breed_code FROM Dogs WHERE abandoned_yn = 'no' GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM Breeds WHERE abandoned_yn = 'no' GROUP BY breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.owner_id , t2.last_name FROM Owners AS t1 JOIN Dogs AS t2 ON t1.owner_id = t2.owner_id JOIN Treatments AS t3 ON t2.dog_id = t3.dog_id WHERE t3.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments ORDER BY cost_of_treatment DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM Treatments GROUP BY treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM Treatment_Types WHERE cost_of_treatment = (SELECT min(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.zip_code FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.date_of_birth = 'null' ORDER BY T1.weight DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(treatment_type_code) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals GROUP BY professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home , T2.home_phone FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name FROM Treatments AS T1 JOIN PROFESSIONS AS T2 ON T1.profession_id = T2.profession_id JOIN DOG们 AS T3 ON T1.dog_id = T3.dog_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T3.first_name , T3.last_name FROM Treatments AS T1 JOIN Dogs AS T2 ON T1.dog_id = T2.dog_id JOIN Professionals AS T3 ON T1.profession_id = T3.profession_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , T2.role_code FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.profession_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM Treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM Treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.weight FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.weight FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T1.breed_name = \"Rare_Standard\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T1.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = 'VA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = 'VA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_departed FROM dogs ORDER BY date_departed", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_departed FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT t2.last_name FROM dogs AS t1 JOIN owners AS t2 ON t1.owner_id = t2.owner_id ORDER BY t1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM PROFESSIONALS WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_departed , date_arrived FROM dogs WHERE abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM Treatments AS T1 JOIN Dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.treatment_type_code = \"Treatment\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.professional_id WHERE T1.role_code = 'Doctor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM Professionals AS T1 JOIN Dogs AS T2 ON T1.profession_id = T2.profession_id WHERE T2.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name FROM professionals WHERE city LIKE \"%West%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT T1.name FROM BREEDS AS T1 JOIN PROFESSIONS AS T2 ON T1.breed_code = T2.breed_code WHERE T2.city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.breed_code = \"North\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT T2.first_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'no' AND age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 'no' AND age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Treatments AS T1 JOIN Dogs AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE abandoned_yn = 'no' AND breed_code = 'spatter' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN (SELECT owner_id FROM Dogs WHERE abandoned_yn = 'no')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = \"no\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , cost_of_treatment FROM Treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM CHARGE;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charize_amount) FROM Charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name FROM PROFESSIONS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name FROM professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_type , size_type FROM Breeds AS T1 JOIN Sizes AS T2 ON T1.size_code = T2.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT breed_type , size_type FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.profession_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T2.Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizens != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T1.birth_year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T2.birth_year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT COUNT(*) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , count(*) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT citizenship FROM singer GROUP BY citizenship ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_worth_millions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_worth_millions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT T2.Title FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T1.Sale DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT T2.Title FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T1.Highest_Position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sale_Millions > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , T1.Highest_Position FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T1.Highest_Position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , MAX(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sale_Year = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 GROUP BY citizenship", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..cbb8152f46d8106e128f7829546377786d32904c --- /dev/null +++ b/infer/qwen/spider_dk/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = '2001'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM station WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , highest FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.name , t2.capacity FROM concert AS t1 JOIN stadium AS t2 ON t1.stadium_id = t2.stadium_id WHERE t1.year >= 2014 GROUP BY t1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg_average FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.Name , T2.Theme , COUNT(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID JOIN concert AS T3 ON T2.concert_ID = T3.concert_ID GROUP BY T3.Theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT t1.lowest , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT t1.lowest , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT max(weight) FROM Pets WHERE pettype = \"dog\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = \"F\" AND T1.Fname = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T2.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.lname , T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.lname , T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID NOT IN (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Dog\" EXCEPT SELECT DISTINCT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\" EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE birthdate > \"2020\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE birthdate > \"2020\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.PetID IN (SELECT PetID FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.name , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM has_pet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T1.stuid = T3.stuid WHERE T3.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.PetID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID WHERE T1.StuID = (SELECT StuID FROM Student WHERE LName = 'Smith')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT StuID , count(*) FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.birthdate = \"2001\"PETTYPE = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = \"2001\" PETTYPE = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.Continent GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT t1.continent , count(*) , t1.continent FROM continents AS t1 JOIN countries AS t2 ON t1.contid = t2.continent GROUP BY t1.continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE YEAR > 2019", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T2.year < 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid ORDER BY T2.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.Maker , t2.Year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.model WHERE t2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.Year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.Continent = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE T1.fullname = \"Ford Mustang GT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'AMC Hornet Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"Japan\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers WHERE countryname = \"Japanese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(DISTINCT t1.model) FROM model_list AS t1 JOIN car_makers AS t2 ON t1.maker = t2.id WHERE t2.fullname = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T2.FullName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" GROUP BY T2.Maker HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Make FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3 GROUP BY T2.Make", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN cars_data AS T3 ON T2.model = T3.id WHERE T3.Cylinders = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(T2.Edispl) FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model WHERE T3.Model = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT accelerate , cylinders FROM cars_data ORDER BY accelerate DESC GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.Model FROM car_names AS t1 JOIN model_list AS t2 ON t1.Model = t2.Model JOIN car_makers AS t3 ON t2.Maker = t3.Id GROUP BY t2.Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.model FROM model_list AS t1 JOIN car_names AS t2 ON t1.model = t2.model GROUP BY t2.model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2019", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = 'American'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T1.Id FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T1.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = \"General Motors\" UNION SELECT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN cars_data AS T3 ON T3.id = T2.model WHERE T1.Maker = \"General Motors\" OR T3.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(cylinders) FROM cars_data WHERE make = \"Tesla\" ORDER BY accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE make = \"Tesla\" ORDER BY accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullName FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders != 4)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM cars_data WHERE horsepower != (SELECT min(horsepower) FROM cars_data) AND cylinders != 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "{\"sql\": \"SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.fullname = 'Ford Motor'}}", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T1.model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid WHERE T2.fullname = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" OR T2.Model = \"Tesla\" GROUP BY T1.CountryId HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Tesla\" GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"BMW\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Abbreviation = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = 'Jetblue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE countryabbreviation = 'JAC'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE Country = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.CountryAbbreviation = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.Abbreviation = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abnovation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.Airline = 'JetBlue' AND T2.AirportName = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ASY Airport\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airline = 'JetBlue' AND T2.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"AHD\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.City = \"Aberdeen\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.destairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.DestAirport ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T2.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T2.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T2.SourceAirport = T3.AirportCode WHERE T3.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T2.SourceAirport = T3.AirportCode WHERE T3.AirportName = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T2.SourceAirport = T3.AirportCode WHERE T3.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID HAVING COUNT(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline HAVING sum(T1.UID) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FL, T1.DestAirport FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Sydney\" OR T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Syracuse\" OR T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights OR sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE template_id IN (SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT T1.template_id , count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , Template_ID FROM Documents GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_Effective_from , T1.date_Effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT Template_ID FROM Templates EXCEPT SELECT Template_ID FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT Template_ID FROM Templates EXCEPT SELECT Template_ID FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT Date_Effective_From , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Date_Effective_From < Date_Effective_To", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Date_Effective_To - Date_Effective_From > 0.5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , template_type_code FROM Templates WHERE Version_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(version_number) , min(date_effective_from) , min(date_effective_to) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT version_number , date_effective_from , date_effective_to FROM Templates ORDER BY version_number ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Document_Name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM documents AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from , T1.date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_Effective_from , date_Effective_to FROM Templates EXCEPT SELECT T1.date_Effective_from , T1.date_Effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Paragraphs AS T2 ON T1.template_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Description = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.loser_age , T2.player_id FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.result , T2.birth_date FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT loser_age , winner_age FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT T1.ranker , avg(T2.ranker) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T2.ranker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(loser_rank) FROM matches UNION SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T1.ranking) , T1.player_id FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id UNION SELECT max(T1.ranking) , T1.player_id FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(ranking) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY tours DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY sum(T1.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1 UNION SELECT T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id WHERE T1.tourney_name = \"Australian Open\" ORDER BY T1.loser_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank_points DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_entry FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_entry ORDER BY max(minutes) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T2.loser_hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.birth_date FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM Addresses ORDER BY line_1 , line_2 , line_3 LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , count(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY YEAR_of_founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_of_founded = (SELECT min(YEAR_of_founded) FROM orchestra)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_of_founded < 2003 GROUP BY record_company HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003 GROUP BY Record_Company HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE RESULT = \"if_first_show\" AND IF_Glebe_Park = \"Yes\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE RESULT = \"if_first_show\" AND 如果_first_show = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 'yes') GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 'yes') GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT DISTINCT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT DISTINCT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals EXCEPT SELECT first_name FROM dogs WHERE name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals EXCEPT SELECT T1.first_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name FROM professionals EXCEPT SELECT T1.professional_id , T2.first_name FROM professionals AS T1 JOIN dogs AS T2 ON T1.professional_id = T2.date_arrived", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals EXCEPT SELECT T1.professional_id , T2.first_name , T2.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T3.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.home_phone , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.home_phone FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.abandoned_yn = '1' GROUP BY T2.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.abandoned_yn = 1 GROUP BY T2.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.charge_amount LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type_code GROUP BY T1.treatment_type_code ORDER BY sum(T2.charge_amount) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.abandoned_yn) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.street , T1.city , T1.state , T1.zip_code , T1.last_name , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T4.size FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T4.weight FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T4.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.gender = 'dog' AND T1.breed_code = (SELECT breed_code FROM dogs GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.gender = 'Dog' ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments WHERE treatment_type_code = \"therapy\" INTERSECT SELECT date_departed - date_arrived FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments WHERE treatment_type_code = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'yes' AND age < (SELECT avg(age) FROM dogs WHERE abandoned_yn = 'yes')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'yes' AND age < (SELECT avg(age) FROM dogs WHERE abandoned_yn = 'yes')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'yes' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.abandoned_yn = 'yes' EXCEPT SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE abandoned_yn = 'yes' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments );", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments );", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charge_amount) FROM Charges ORDER BY charge_type DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_type , size_type FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T4.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T2.professional_id = T1.professional_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , MAX(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Name NOT IN (SELECT T3.Name FROM singer AS T3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..b13659c23d34e4c39d9650e2ee399680176a94a1 --- /dev/null +++ b/infer/qwen/spider_dk/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer ORDER BY Birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Birthday = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , Name FROM stadium WHERE Capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.Stadium_ID = T2.Stadium_ID GROUP BY T1.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.Stadium_ID FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID GROUP BY T1.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT T1.concert_name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id ORDER BY T1.year DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT max(attendance) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.name = 'highest' EXCEPT SELECT max(attendance) FROM concert AS T2 JOIN singer_in_concert AS T3 ON T2.concert_id = T3.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT min(lowest) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE Stadium_ID NOT IN (SELECT T1.Stadium_ID FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID WHERE T1.Year = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT min(lowest) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.Name , T3.Theme , COUNT(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T1.Singer_ID = T3.Singer_ID GROUP BY T2.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T2.Name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID JOIN concert AS T3 ON T1.concert_ID = T3.concert_ID WHERE T3.Year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.Year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(T1.lowest) , min(T1.lowest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT max(T1.lowest) , min(T1.lowest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.Lowest , T1.Highest FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T2.Year = 2014 INTERSECT SELECT T1.Lowest , T1.Highest FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T2.Year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT highest FROM stadium ORDER BY capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE birthdate = (SELECT min(birthdate) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE birthdate = (SELECT min(birthdate) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F' AND T2.PetType = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F' AND T1.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = Pets.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE birthdate > \"2020\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > '2020'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(PetID) , max(PetID) FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(petid) , max(petid) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(petid) , max(petid) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.PetID = (SELECT PetID FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM has_pet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T1.stuid = T3.stuid WHERE T3.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.PetID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT T1.StuID , count(*) FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID GROUP BY T1.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid GROUP BY T1.Stuid HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Fname , T2.Sex FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.birthdate = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Students WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Students WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T2.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY max(horsepower) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.year >= 2023 - 1 AND T2.year <= 2023 + 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.model WHERE T2.model >= (SELECT max(YEAR) FROM cars_data WHERE YEAR >= 2023) AND T2.model <= (SELECT max(YEAR) FROM cars_data WHERE YEAR >= 2021)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id ORDER BY T2.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Model <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.MakeId WHERE T1.year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , COUNT(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.fullname FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"Amc\" AND model = \"Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"AMC Hornet Sportabout\" AND horsepower LIKE \"sw\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'Japan'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullName LIKE \"%Japanese care%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"america\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(mpg) FROM cars_data WHERE cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT maker , model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T2.Maker , T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker != \"null\" GROUP BY T2.Country HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker != \"null\" GROUP BY T1.CountryName HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , AVG(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , avg(year) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1 Continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , make FROM cars_data WHERE cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , make FROM cars_data WHERE cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Id IN (SELECT Id FROM cars_data WHERE Make = \"Tesla\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model JOIN cars_data AS T3 ON T2.MakeId = T3.MakeId GROUP BY T1.Model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 2023 OR YEAR = 2024", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 2022 OR YEAR = 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname LIKE \"%American Motor%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.country = 'American'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T2.FullName FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T1.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Maker = T2.Id WHERE T2.Weight > 3500 UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Maker = T2.Id WHERE T2.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(cylinders) FROM cars_data WHERE make = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 GROUP BY model ORDER BY max(horsepower) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders != 4)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM car_names WHERE model NOT IN (SELECT model FROM cars_data WHERE horsepower = (SELECT min(horsepower) FROM cars_data)) AND cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.Model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId WHERE T2.Maker = 'Ford Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.id WHERE T2.maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 AND T2.model >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE T2.fullname LIKE '%tesla%' GROUP BY T1.id HAVING count(*) > 3 UNION SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Tesla\" GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' AND T1.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T1.destairport = 'Ashley' AND T1.sourceairport = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport IN (SELECT airportcode FROM airports WHERE airportname = \"Jetblue\") AND DestAirport IN (SELECT airportcode FROM airports WHERE airportname = \"Jetblue\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'ASY' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ASY\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"AHD\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 2116", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT airline FROM flights GROUP BY airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT airline FROM flights GROUP BY airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T2.SourceAirport = T3.AirportCode WHERE T3.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'CVO' EXCEPT SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceairport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Syracuse\" OR T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Syracuse\" OR T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT sourceairport FROM flights UNION SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT sourceairport FROM flights UNION SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM Documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\" AND template_id = (SELECT template_id FROM Documents WHERE document_name = \"Robbin CV\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID , count(*) FROM Documents GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , template_id FROM Documents GROUP BY template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.date_effective_from FROM Templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_from < date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT version_number , date_effective_from , date_effective_to FROM Templates ORDER BY version_number ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T2.document_id , T2.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.date_effective_from FROM Templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Paragraphs AS T2 ON T1.template_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Paragraphs AS T2 ON T1.template_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.template_type_code = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.loser_age , T2.loser_age FROM matches AS T1 JOIN matches AS T2 ON T1.loser_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T2.loser_age , T1.match_num FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT T1.rank , T2.rank , T1.winner_rank , T2.loser_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id UNION SELECT T1.rank , T2.rank , T1.winner_rank , T2.loser_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(T2.ranking) FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id UNION SELECT avg(T2.ranking) FROM matches AS T1 JOIN rankings AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T2.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T2.player_id = T3.winner_id UNION SELECT max(T2.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T2.player_id = T3.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T2.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T2.player_id = T3.loser_id UNION SELECT max(T2.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T2.player_id = T3.winner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 OR T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players WHERE birth_date = (SELECT max(birth_date) FROM players)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY tours DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T1.player_id = T3.player_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id JOIN players AS T3 ON T1.winner_id = T3.player_id WHERE T2.ranking_points = (SELECT max(ranking_points) FROM rankings WHERE tourney_name = \"Australian Open\") AND T3.country_code = \"Australia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.first_name , T1.last_name ORDER BY T2.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM matches AS T1 JOIN matches AS T2 ON T1.winner_id = T2.loser_id WHERE T1.minutes = (SELECT max(minutes) FROM matches)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , avg(T2.ranking) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(ranking_points) , T1.first_name , T1.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.ranking_points) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.match_num ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.orchestra_id = (SELECT orchestra_id FROM orchestra ORDER BY T2.orchestra_id LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T1.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , count(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY year_of_founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC LIMIT 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT T1.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded <= 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE YEAR_of_Founded > 2003 GROUP BY Record_Company HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'Yes' AND RESULT = 'First' AND DATE = '2023-04-12' AND ATTENDANCE = 1000 AND LOCATION = 'Glebe Park'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'Yes' AND RESULT = 'First' AND ATTENDANCE > 1000 INTERSECT SELECT count(*) FROM show WHERE if_first_show = 'Yes' AND RESULT = 'First' AND ATTENDANCE > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id IN (SELECT performance_id FROM show WHERE if_first_show = 0 EXCEPT SELECT performance_id FROM show WHERE if_first_show = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE Type != \"Non-first\" GROUP BY TYPE HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\" UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\" UNION SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals EXCEPT SELECT T1.first_name FROM Professionals AS T1 JOIN Dogs AS T2 ON T1.professional_id = T2.professional_id WHERE T2.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals EXCEPT SELECT T1.first_name FROM Professionals AS T1 JOIN Dogs AS T2 ON T1.professional_id = T2.professional_id WHERE T2.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.dog_id NOT IN (SELECT T1.dog_id FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"dog\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.cell_number FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.home_phone FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.gender = 'Male' GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.home_phone FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.size_description FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.weight FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id JOIN Breeds AS T3 ON T1.breed_code = T3.breed_code WHERE T3.breed_name = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN breeds AS T3 ON T1.breed_code = T3.breed_code WHERE T3.breed_name = 'Rare' ORDER BY T2.date_of_treatment LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(Dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(Dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"male\" AND T3.age >= 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'male' AND T3.weight > 5;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = '1' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(Dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = '1' EXCEPT SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE abandoned_yn = '1')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = 'dog' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_name , size_description FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , MAX(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID EXCEPT SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..69d7c04ba2e45a9f61b03775f9476073d6302a2f --- /dev/null +++ b/infer/qwen/spider_dk/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT Name , Country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE Country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer ORDER BY Birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Birthday > (SELECT avg(Birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY Average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.Stadium_ID FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID GROUP BY T1.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.highest FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "{\"sql\": \"SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest = (SELECT max(average) FROM stadium WHERE highest - lowest", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT min(lowest) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.name , T2.theme , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.Year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(T1.lighest) , min(T1.lighest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT max(T1.lighest) , min(T1.lighest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(T1.lighest) , min(T1.lighest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT max(T1.lighest) , min(T1.lighest) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T1.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE birthdate = (SELECT min(birthdate) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Major , Age FROM Student EXCEPT SELECT T1.Major , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.pettype = \"Puppy\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.pettype = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE birthdate > \"2020-01-01\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > \"2020\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'M'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM has_pet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T1.stuid = T3.stuid WHERE T3.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT PetID FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT T1.stuid , count(*) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid GROUP BY T1.stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.Continent , T2.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.Continent , T2.ContId , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T2.Model >= 2019 AND T2.Model <= 2021", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T2.Model >= (SELECT min(Model) FROM cars_data WHERE YEAR >= 2019) AND T2.Model <= (SELECT max(Model) FROM cars_data WHERE YEAR >= 2019)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "{\"sql\": \"SELECT T1.Make , T2.Year FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Make FROM car", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Accelerate WHERE T2.Year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT t1.Continent , count(*) FROM continents AS t1 JOIN countries AS t2 ON t1.ContId = t2.Continent GROUP BY t1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Continent = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid GROUP BY t1.countryname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.maker = (SELECT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT T2.Maker , T2.Maker , T1.Model , T1.Model , T1.Model , T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE makeid IN (SELECT id FROM car_makers WHERE fullname = \"AMC Hornet Sportabout\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE model = \"AMC Hornet Sportabout\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = 'Japan'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.countryname = \"Japanese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T2.Maker , T3.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker JOIN car_names AS T3 ON T2.Model = T3.Model", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T2.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country FROM T1 WHERE T1.CountryName != \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T2.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T2.CountryId HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT AVG(Weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryId HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid WHERE t1.countryname = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Maker FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T2.Horsepower) , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T1.Make , T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model ORDER BY T2.MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE makeid IN (SELECT id FROM car_names WHERE model = \"Tesla\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , Cylinders FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) FROM cars_data BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.MakeId = T2.Model AND T1.MakeId NOT IN (SELECT MakeId FROM cars_data) GROUP BY T2.Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM model_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 2023 OR YEAR = 2022", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2019 AND YEAR <= 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.maker = 'American'}\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname LIKE \"%American%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker JOIN car_names AS T3 ON T3.Model = T2.Model WHERE T1.Maker = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model JOIN cars_data AS T3 ON T2.Model = T3.Model WHERE T3.Weight > 3500 OR T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND MAKE = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"Toyota\" AND cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 4 GROUP BY T2.Model ORDER BY AVG(T1.Horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data) AND cylinders != 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM car_names WHERE makeid IN (SELECT makeid FROM cars_data WHERE horsepower FROM cars_data ORDER BY cylinders LIMIT 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.id = T2.model WHERE T1.make = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries EXCEPT SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries EXCEPT SELECT t1.CountryName FROM countries AS t1 JOIN car_makers AS t2 ON t1.CountryId = t2.CountryId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'Tesla' GROUP BY T1.CountryId HAVING COUNT(*) > 3 UNION SELECT T1.CountryId , T2.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE countryabbreviation = \"JAX\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Syracuse\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport IN (SELECT airportcode FROM airports WHERE city = 'Jackson')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destAirport = T2.airportCode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = 'Syracuse' AND T1.DestAirport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Syracuse\" INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE destairport NOT IN (SELECT DISTINCT T1.destairport FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = \"Jetblue\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ASY' AND T1.Airline = 132", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY Airport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airline = 1234", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD Airport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM flights GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.UID ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abd, T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T2.Airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.destairport WHERE T3.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.airportname = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.destairport WHERE T3.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.SourceAirport INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T2.SourceAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline HAVING COUNT(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING COUNT(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING COUNT(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"JETBLUETL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'Syracuse' OR T2.AirportName = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = 'Syracuse' OR T1.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\" AND template_id = (SELECT id FROM Templates WHERE template_type_code = \"CV\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT t1.template_id) FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT t1.template_id) FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE Template_ID IN (SELECT T1.Template_ID FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.version_number = 1 AND T2.document_name = \"PPT\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , T1.template_id FROM documents AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT document_id , template_id FROM documents GROUP BY document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT T1.template_id FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT t1.template_id FROM documents AS t1 JOIN paragraphs AS t2 ON t1.template_id = t2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_from < date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_to - date_effective_from > 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T2.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_effective_from FROM templates GROUP BY date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Documents AS T2 ON T1.template_type_code = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE template_type_code = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.winner_age , T2.match_num FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.winner_age , T2.match_num FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT T1.rank , T2.rank FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id UNION SELECT T1.rank , T2.rank FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) , avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id WHERE YEAR = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T2.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.ranking_points = (SELECT max(ranking_points) FROM rankings AS T3 JOIN matches AS T4 ON T3.player_id = T4.winner_id WHERE T4.tourney_name = \"Australian Open\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id WHERE T2.ranking_points = (SELECT max(ranking_points) FROM rankings WHERE tourney_name = 'Australian Open')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name , T2.minutes FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.minutes ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T2.player_id = T3.winner_id ORDER BY T3.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT ranking_points , T1.first_name , T1.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , count(*) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , count(*) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T2.winner_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , count(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY year_of_founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT orchestra FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT orchestra FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded <= 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded > 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1 AND RESULT = \"First\" AND DATE = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 1 AND result = \"First\" AND name = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE T2.If_first_show = 'No' GROUP BY T1.Type HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 'Yes') GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals INTERSECT SELECT state FROM Owners", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\" UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T3.email_address > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals UNION SELECT first_name FROM owners WHERE role_code = 'Professional' OR role_code = 'Owner' EXCEPT SELECT T1.first_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals UNION SELECT first_name FROM owners WHERE role_code = 'professional' OR role_code = 'owner' EXCEPT SELECT T1.first_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments WHERE dog_id = 'dog_id')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.home_phone , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.cell_number FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(T1.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.cell_number FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T3.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code WHERE T3.treatment_type_description = \"therapy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM treatments JOIN treatment_types ON treatments.treatment_type_code = treatment_types.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM treatments AS T JOIN treatment_types AS D ON T.treatment_type_code = D.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.size_description FROM Sizes AS T1 JOIN Dogs AS T2 ON T1.size_code = T2.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.size_code FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = (SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = (SELECT breed_code FROM dogs ORDER BY count(*) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.date_arrived > '1990-01-01' AND D.date_departed < '1990-01-02'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = 'M'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = 'A'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = 'A'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments WHERE treatment_type_code = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = '1' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE abandoned_yn = '1')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE dog_id = 'dog' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments WHERE dog_id IN (SELECT dog_id FROM dogs))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.treatment_type_description FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY birth_year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Name NOT IN (SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..6d9cc9192a95d67d2b42a488aa57601efeeda80d --- /dev/null +++ b/infer/qwen/spider_dk/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , highest FROM stadium GROUP BY highest", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.stadium_id , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT highest FROM stadium WHERE name NOT IN (SELECT DISTINCT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT lowest FROM stadium EXCEPT SELECT T1.lowest FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.computer_name , T1.theme , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM singer_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T1.singer_id = T3.singer_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_ID = T3.concert_ID GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year < 2014 OR T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT t1.name , t1.highest , t1.lowest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT t1.name , t1.highest , t1.lowest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.lowest , T2.highest FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id WHERE T2.year = 2014 INTERSECT SELECT T2.lowest , T2.highest FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = (SELECT max(YEAR) FROM concert) ORDER BY T1.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE birthdate = (SELECT min(birthdate) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T1.Fname != \"Unknown\" AND T1.lname != \"Unknown\" AND T1.age != 0 AND T1.Major != \"Unknown Major\" AND T1.city_code != \"Unknown\" AND T2.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T2.PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID WHERE T2.PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.Fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Has_Pet WHERE pettype = \"Puppy\") EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Has_Pet WHERE pettype = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > \"2020-01-01\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE birthdate > \"2020-01-01\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T1.lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = \"2001-01-01\" AND T2.pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , COUNT(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.Continent GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT t1.continent , t2.contid , count(*) FROM continents AS t1 JOIN countries AS t2 ON t1.contid = t2.contid GROUP BY t1.contid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T2.year > 2022", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE T2.year > 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.Year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.Maker , t2.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.id ORDER BY t2.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.Mileage >= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , count(*) FROM car_makers AS T1 JOIN continents AS T2 ON T1.Country = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid GROUP BY t1.countryname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T1.Maker = \"Amherst\" AND T2.Model = \"Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.MPG FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model WHERE T3.Maker = 'AMC Hornet Sportabout' AND T1.Accelerate = 180", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"Toyota\" OR maker = \"Honda\" OR maker = \"Ford\" OR maker = \"BMW\" OR maker = \"Chevrolet\" OR maker = \"Tesla\" OR maker = \"Nissan\" OR maker = \"Toyota\" OR maker = \"Honda\" OR maker = \"Ford\" OR maker = \"BMW\" OR maker = \"Chevrolet\" OR maker = \"Tesla\" OR maker = \"Nissan\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers WHERE make = 'Japanese care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = 'Ford' AND T2.model = 'F1' AND T1.country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT Weight FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Country FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker != \"Unknown\" GROUP BY T1.CountryName HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.Continent = \"Europe\" GROUP BY T1.CountryHARD HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Ford\" INTERSECT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T2.Country ORDER BY count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Maker FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T1.Cylinders = 3 GROUP BY T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T2.Horsepower) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker WHERE T2.Cylinders = 3 GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT t1.Model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.Id = t2.MakeId ORDER BY t1.MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.MPGas = (SELECT max(MPG) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , Cylinders FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.Model FROM car_names AS t1 JOIN model_list AS t2 ON t1.Model = t2.Model WHERE t1.Make = (SELECT t1.Make FROM car_names GROUP BY t1.Make ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.maker FROM car_makers AS t1 JOIN car_names AS t2 ON t1.id = t2.model GROUP BY t1.maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2020 AND YEAR < 2021", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2023 AND YEAR <= 2024", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = \"American Motor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Id IN (SELECT T1.Id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Weight > 3500)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Maker = T2.Model JOIN car_makers AS T3 ON T3.Id = T2.MakeId WHERE T3.Maker = 'General Motors' OR T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(Cylinders) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Tesla\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers WHERE make > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders != 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM car_names WHERE cylinders < 4 INTERSECT SELECT makeid , fullname FROM cars_data WHERE Horsepower != (SELECT min(Horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight > 3500 EXCEPT SELECT T3.Model FROM car_makers AS T3 JOIN model_list AS T4 ON T3.Id = T4.Maker WHERE T3.FullName = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.weight < 3500 EXCEPT SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.weight < 3500 AND T2.Maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.model GROUP BY T1.id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "{\"sql\": \"SELECT T1.Id , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireHireH", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryID HAVING count(*) > 3 UNION SELECT CountryId , CountryName FROM cars_data AS T3 JOIN car_names AS T4 ON T3.MakeId = T4.ModelID JOIN country AS T2 ON T2.CountryID = T3.CountryID GROUP BY T3.CountryID HAVING T4.Mileage = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Abbreviation = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = 'Jetblue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE country = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' AND T1.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T1.sourceairport = 'Syracuse' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline WHERE T2.Abbreviation = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline WHERE T2.Abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'ASY' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ASY\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"AHD\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"AHD\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.AirportName = 'Aberdeen' AND T1.Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Aberdeen\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT DestAirport FROM flights GROUP BY DestAirport ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T2.Airline ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN airports AS T2 ON T1.Abbreviation = T2.AirportCode GROUP BY T1.Abbreviation ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.SourceAirport WHERE T3.AirportName = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airliner GROUP BY T1.Airliner HAVING sum(count(*) ) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING sum(T1.FlightNo) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FLIGHTNO FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT FlightNo FROM flights WHERE DESTAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Syracuse' OR T2.airportname = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Syracuse' OR T2.airportname = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights) AND NOT IN (SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights) - (SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM DOCUMENTS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.template_details = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , template_id FROM Documents GROUP BY template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , template_id FROM Documents GROUP BY template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT document_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT template_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Template_Type_Code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE date_effective_from < date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_Effective_from , date_Effective_to FROM Templates WHERE date_Effective_to - date_Effective_from > 14天", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , template_type_code FROM Templates WHERE Version_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_ffective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT date_effective_from , count(*) FROM Templates GROUP BY date_effective_from", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT date_effective_from FROM Templates GROUP BY date_effective_from HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(version_number) , date_effective_from , date_effective_to FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT version_number , date_effective_from , date_effective_to FROM Templates ORDER BY version_number ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T2.template_id , T2.template_type_code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from , T1.date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T2.date_effective_from , T2.date_effective_to , count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date_Effective_from FROM Documents GROUP BY date_Effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE document_id NOT IN (SELECT document_id FROM Paragraphs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE document_id NOT IN (SELECT document_id FROM Documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM ref_template_types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.template_type_code = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT date_effective_from FROM Templates WHERE Template_Type_Code = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.loser_age FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT loser_age FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT T1.ranking , T2.player_id FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) + avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T1.ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id UNION SELECT max(T1.ranking) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.winner_name , T1.winner_entry FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY tours DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.ranking_points = (SELECT max(ranking_points) FROM matches WHERE tourney_name = \"Australian Open\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.name ORDER BY max(T1.minutes) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name , T2.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.loser_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.looser_age DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"right\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T2.birth_date FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID ORDER BY T2.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , count(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id JOIN show AS T3 ON T2.performance_id = T3.performance_id ORDER BY YEAR_of_founded LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT orchestra FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT T1.record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id JOIN organization AS T3 ON T2.performance_id = T3.performance_id WHERE T1.year_of_founded < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE IF_first_show = 1 AND RESULT = \"first\" AND DATE = \"Glebe Park\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'yes' AND Performance_ID IN (SELECT Performance_ID FROM performance WHERE Official_ratings_(_) = \"Glebe Park\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.type FROM performance AS T1 JOIN show AS T2 ON T1.performance_id = T2.performance_id WHERE T2.if_first_show = 'no' GROUP BY T1.performance_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 1) GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM OWNERS INTERSECT SELECT state FROM PROFESSIONALS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM OWNERS INTERSECT SELECT state FROM PROFESSIONALS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 AND state = 'Indiana'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T3.owner_id = T2.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals EXCEPT SELECT first_name FROM dogs WHERE name LIKE \"%dog%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM PROFESSIONALS EXCEPT SELECT name FROM Dogs WHERE name LIKE '%dog%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"dog\" EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.home_phone , T2.cell_number FROM professionals AS T1 JOIN owners AS T2 ON T1.professional_id = T2.owner_id GROUP BY T1.professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.home_phone FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = 1 GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM Dogs AS T1 JOIN Breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '0' GROUP BY T2.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type WHERE T2.charge_type = 'treatment' ORDER BY sum(T2.charge_amount) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN owners AS T2 ON T1.treatment_type_code = T2.owner_id WHERE T1.treatment_type_code = (SELECT treatment_type_code FROM treatments GROUP BY treatment_type_code ORDER BY sum(cost_of_treatment) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T2.first_name , T2.last_name FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id JOIN treatments AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.size FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T2.size_code = T3.size_code WHERE T3.size = '13.5'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.weight FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = (SELECT breed_code FROM dogs GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.gender = \"M\" AND T2.treatment_type_code = \"RARE\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = 'dog' AND D.date_departed > date_of_birth AND D.date_departed < date_of_birth + 7天", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = 'therapy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments WHERE treatment_type_code = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM PROFESSIONALS WHERE city LIKE \"%West%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = '1' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.abandoned_yn = 0 EXCEPT SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE abandoned_yn = 'yes')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments AS T JOIN Dogs AS D ON T.dog_id = D.dog_id WHERE gender = \"dog\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments );", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM CHARGES", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , sum(charge_amount) FROM Charges GROUP BY charge_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM PROFESSIONALS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM PROFESSIONALS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , MAX(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..5be82b31ec538b5d60ffe88886254c4998ff6343 --- /dev/null +++ b/infer/qwen/spider_dk/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T1.height FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year > 2013 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT max(attendance) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT min(low) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT country FROM singer WHERE birthday = 1981 OR birthday = 1991", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(*) FROM stadium EXCEPT SELECT avg(*) FROM concert WHERE YEAR = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT min(low) FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR < 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.theme , count(*) , T1.cconcert_name FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.cconcert_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.theme , count(*) , T1.cconcert_name FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.cconcert_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.year > 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.songer_id = T2.songer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year < 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.Low , T2.High FROM concert AS T1 JOIN stadium AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T1.Year = 2014 INTERSECT SELECT T2.Low , T2.High FROM concert AS T1 JOIN stadium AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T1.Year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT min(weight) FROM pets WHERE pettype = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM pets AS T1 JOIN has_pet AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T3.stuid = T2.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM pets AS T1 JOIN has_pet AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T3.stuid = T2.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM pets AS T1 JOIN has_pet AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T3.stuid = T2.stuid WHERE T3.sex = \"F\" AND T1.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM pets AS T1 JOIN has_pet AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T3.stuid = T2.stuid WHERE T3.sex = 'F' AND T1.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" OR T3.PetType = \"Pupdog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetType = \"Cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT fname , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetID = \"dog\" INTERSECT SELECT StuID FROM Has_Pet WHERE PetID = \"puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT fname FROM student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID = \"Puppy\" EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT petid , weight FROM pets WHERE birthdate > 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM pets WHERE birthdate > 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) , max(weight) FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) , max(weight) FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) , max(weight) FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"animal\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT petid FROM haspet AS T1 JOIN student AS T2 ON T1.stuid = T2.stuid WHERE T2.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT petid FROM haspet AS T1 JOIN student AS T2 ON T1.stuid = T2.stuid WHERE T2.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T2.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T2.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = 2001 AND T3.pettype = 'Cat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate = 2001 AND T1.sex = 'Cat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(DISTINCT continent) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.Countid , T1.CountryName , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Countid = T2.Countid GROUP BY T1.Countid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.countid , T1.countryname , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.countid = T2.countid GROUP BY T1.countid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FirstName , T2.Model , COUNT(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , count(*) , T2.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T2.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT Model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT Model FROM cars_data WHERE Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT Model FROM cars_data WHERE Weight < (SELECT avg(Weights) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.year < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.ID = T2.MakeId WHERE T2.Year < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.ID = T2.MAKEID ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.ID = T2.MakeId ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.MakeId = T2.MakeId WHERE T1.Year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.MakeId = T2.Model WHERE T1.year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Countid , COUNT(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T2.Countid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Countinent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.Countinent = T2.Country GROUP BY T1.Countinent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.fullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.Accelerate FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId JOIN car_names AS T3 ON T2.Country = T3.MakeId WHERE T3.Sportabout = \"amc hornet\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.Accelerate FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T2.Sporting = \"Amc\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE Country = \"Japanese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"Japanese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = 'Americano'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id JOIN countries AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , avg(YEAR) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T2.Horsepower) , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Maker FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE model = \"tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_makers GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM model_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = (SELECT max(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = -2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.Maker = \"American Motor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.Maker = \"American Motor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Name FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T2.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Name , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T2.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.id WHERE T2.Maker = \"General Motors\" OR T1.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.id JOIN cars_data AS T3 ON T3.id = T2.makeid WHERE T3.weight > 3500 OR T2.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE Weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM (SELECT country FROM car_makers GROUP BY country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower DESC LIMIT 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM car_makers WHERE horsepower > (SELECT min(horsepower) FROM cars_data) EXCEPT SELECT T1.id , T1.name FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.cylinders > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , model FROM cars_data WHERE horsepower < (SELECT min(horsepower) FROM cars_data) AND cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.id WHERE T2.Maker = 'Ford Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id JOIN cars_data AS T3 ON T3.id = T2.makeid WHERE T3.weight < 3500 EXCEPT SELECT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id JOIN cars_data AS T3 ON T3.id = T2.makeid WHERE T2.Maker = \"Ford Motor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.Maker HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.Country , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.Country , T1.CountryName FROM countries AS T1 JOIN model_list AS T2 ON T1.CountryId = T2.Maker WHERE T2.Model = 'tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.Country , COUNT(*) FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING COUNT(*) > 3 UNION SELECT T1.Country , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING COUNT(*) = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"Americano\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Syracuse\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SOURCE Airport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SOURCE Airport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE destinationairport = (SELECT airportname FROM airports WHERE city = \"Jackson\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Syracuse' AND destinationairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Syracuse\" AND destinationairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE FlightNo = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"JetBlue\" AND T2.destairport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"ASY\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'JetBlue' AND T2.city = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"AHD\" AND Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Aberdeen\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T2.SourceAirport ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.uid ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.uid ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.DestAirport GROUP BY T1.Airline ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.destinationairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.DestAirport WHERE T2.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T2.Airline FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = \"APG\" INTERSECT SELECT T2.Airline FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.Source Airport WHERE T1.AirportName = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T2.DestAirport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T2.Dest Airport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.uid HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport GROUP BY T1.uid HAVING COUNT(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.uid HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.uid HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SOURCE Airport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SOURCE Airport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SOURCE Airport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' OR T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Syracuse\" OR T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights) AND AirportCode NOT IN (SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT sourceairport FROM flights) OR airportcode NOT IN (SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description FROM Documents WHERE document_name = \"Robbin CV\" AND template_id = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT t1.template_id) FROM documents AS t1 JOIN templates AS t2 ON t1.template_id = t2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE Template_ID IN ( SELECT T1.Template_ID FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Description = \"PPT\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROMTemplates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T2.Template_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.dateffective_to - T1.dateffective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.Template_ID FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_ID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.Template_ID FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_ID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT template_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT template_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROMTemplates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROMTemplates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Template_Type_Code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To , Template_Type_Code FROM_templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_To - Date_Effective_From FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective FROM Templates WHERE Date_Effective_To - Date_Effective_From LIKE \"PP\" OR Date_Effective_To - Date_Effective_From LIKE \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROMTemplates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_ffective_from , date_ffective_to FROM Templates WHERE version_number > 5 AND template_type_code = \"Text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Version_Number > 5 AND Template_Type_Code = \"Text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From HAVING COUNT(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From HAVING COUNT(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Date_Effective_From) , min(Date_Effective_To) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROMTemplates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.dateffective_to - T1.dateffective_from FROM_templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.dateffective_to - T1.dateffective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name , document AND template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_id = (SELECT document_id FROM Documents WHERE template_id = \"BK\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , COUNT(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Document_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To , COUNT(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T2.Date_Effective_From , T2.Date_Effective_To", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Date_Effective_From , T1.Date_Effective_To ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.dateffective_from , T1.dateffective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.dateffective_from , T1.dateffective_to ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT template_type_code , template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Documents AS T3 ON T2.Template_ID = T3.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.Template_Type_Code = T2.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM_templates WHERE Template_Type_Description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T2.Template_Type_Description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.match_num FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.age FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'American'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'American'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(loser_rank) , avg(winner_rank) , match_num FROM matches GROUP BY match_num", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(loser_rank) , avg(winner_rank) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id INTERSECT SELECT avg(loser_rank) , avg(winning_rank) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winning_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) , min(winner_rank) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id INTERSECT SELECT max(loser_rank) , min(winner_rank) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT min(loser_rank) , min(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT T2.tourney_name FROM matches AS T1 JOIN tournaments AS T2 ON T1.tourney_id = T2.tourney_id GROUP BY T1.tourney_id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 OR T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 OR T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winning_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winning_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winning_rank , sum(T2.winning_rank_points) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winning_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.rank = T3.player_id WHERE T3.tourney_name = \"Australian Open\" ORDER BY T1.winery_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM MATCHES AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.winery_rank = T3.winery_rank WHERE T3.tourney_name = \"Australian Open\" ORDER BY T3.winery_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name , T1.year FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T1.year DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.rank) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , avg(T2.rank) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.ranking_points) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT count(*) , T1.year FROM matches AS T1 JOIN rankings AS T2 ON T1.rankings = T2.player_id GROUP BY T1.year", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T2.winery_NAME , T2.winery_RANK FROM MATCHES AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winery_NAME ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T2.winery_NAME , T2.winery_RANK FROM MATCHs AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winery_NAME ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T2.winner_id) FROM races AS T1 JOIN matches AS T2 ON T1.winner_id = T2.winner_id WHERE T1.tourney_name = \"WTA Championships\" AND T2.winer_hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM left-handed players AS T1 JOIN MATCH AS T2 ON T1.player_id = T2.winner_id JOIN ROLES AS T3 ON T2.tourney_id = T3.player_id WHERE T3.ranking_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN MATCHS AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winery_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM ADDRES WHERE line_1 != \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'T'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(attendance) FROM show WHERE if_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(attendance) FROM show WHERE if_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT Name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T3.orchitation FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id JOIN performance AS T3 ON T1.performance_id = T3.performance_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.organchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1 conductor_id = T2 conductor_id GROUP BY T1 conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1 conductor_id = T2 conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1 Conduct_ID = T2 Conduct_ID ORDER BY T2.Year_of_Founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , count(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , count(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_OF_Founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_OF_Founded < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_OF_Founded > 2003 INTERSECT SELECT record_company FROM orchestra WHERE YEAR_OF_Founded < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE If_first_show = 'Glebe Park'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE If_first_show = 'Glebe Park'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.type FROM performance AS T1 JOIN show AS T2 ON T1.performance_id = T2.performance_id GROUP BY T1.type HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Type FROM show AS T1 JOIN performance AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE T1.If_first_show = 'No' GROUP BY T2.Type HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T1.owner_id = T3.owner_id WHERE T3.city > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'professional' UNION SELECT first_name FROM owners WHERE role_code = 'owner' EXCEPT SELECT T1.first_name FROM professionals AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'student' OR role_code = 'owner' EXCEPT SELECT name FROM dogs WHERE gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name FROM professionals EXCEPT SELECT T1.professional_id , T1.first_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"animal\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code != \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.abandoned_yn = (SELECT max(abandoned_yn) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.cost_of_treatment ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.total_charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.total_cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN Treatment_Types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.size_code) FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.weight) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = (SELECT min(breed_code) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT name , date_of_treatment FROM dogs WHERE breed_code = (SELECT breed_code FROM dogs GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = 'VA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'VA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE treatment_type_code = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = 'HI' OR state = 'WI'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = 'HI' OR state = 'WI'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.professional_id) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.name = 'Protoporphyrinogen IX'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T2.professional_id) FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T1.dog_id = T3.dog_id WHERE T3.name = \"Professional\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'no' AND age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE abandoned_yn = 'yes' AND age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = \"dog\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = \"dog_id\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1' AND gender = 'male' UNION SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '0' AND gender = 'female'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 'yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , sum(charge_amount) FROM charges GROUP BY charge_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , sum(charge_amount) FROM charges GROUP BY charge_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges GROUP BY charge_type ORDER BY sum(charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges GROUP BY charge_type ORDER BY sum(charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name FROM Professionals WHERE role_code = 'PROF'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name FROM Professionals WHERE role_code = 'PROF'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Sizes AS T2 ON T1.breed_code = T2.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_type , T2.size_type FROM Breeds AS T1 JOIN Sizes AS T2 ON T1.breed_code = T2.size_code WHERE T1.name = \"dogs\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year < 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT common(citation) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(Net_Worth_Millions) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT Title FROM song ORDER BY Sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT Title FROM song ORDER BY Sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Higher_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT max(T2.Highest_Position) , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 GROUP BY Citizenship HAVING COUNT(*) >= 2", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..28565e056c2cf7c433acf6e58374203f1de6c804 --- /dev/null +++ b/infer/qwen/spider_dk/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT Name , Country FROM singer ORDER BY Is_male DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID), min(Singer_ID), max(Singer_ID) FROM singer WHERE Country = \"France\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Singer_ID), min(Singer_ID), max(Singer_ID) FROM singer WHERE Country = \"France\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer WHERE birthday = (SELECT min(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer WHERE Birthday = (SELECT max(Birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday LIKE '2001%';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE YEAR(birthday) = 2001;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Is_male = \"1\" AND AVG(Birthday) > (SELECT avg(Birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Is_male = \"F\" AND Birthday < (SELECT avg(Birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT Location , Name FROM stadium WHERE Capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , NAME FROM stadium WHERE Capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Capacity) , max(Capacity) FROM stadium;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT Average , Highest FROM stadium;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT Name , Capacity FROM stadium ORDER BY Average DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR <= 2014;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR <= 2014;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.stadium_name , COUNT(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.Stadium_ID , COUNT(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.highest FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name , YEAR FROM concert ORDER BY YEAR ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT Highest FROM stadium;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE YEAR(Birthday) = 1981 OR YEAR(Birthday) = 1991;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT Average FROM stadium WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_Name , T1.Theme , COUNT(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_Name , T1.Theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.concert_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT DISTINCT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id WHERE T3.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT DISTINCT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id WHERE T3.year <= 2014;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT DISTINCT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT stadium.Lowest , stadium.Highest FROM stadium JOIN concert ON stadium.Stadium_ID = concert.Stadium_ID WHERE concert.Year = 2014 INTERSECT SELECT stadium.Lowest , stadium.Highest FROM stadium JOIN concert ON stadium.Stadium_ID = concert.Stadium_ID WHERE concert.Year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT stadium.lowest , stadium.highest FROM stadium JOIN concert ON stadium.stadium_id = concert.stadium_id WHERE concert.year = 2014 INTERSECT SELECT stadium.lowest , stadium.highest FROM stadium JOIN concert ON stadium.stadium_id = concert.stadium_id WHERE concert.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM stadium ORDER BY capacity DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM stadium ORDER BY capacity DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT min(birthdate) FROM Pets;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT min(weight) FROM pets WHERE pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT PetType , max(weight) FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT PetType , max(weight) , birthdate FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Age > 20);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Age > 20);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Sex = \"F\") AND PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Sex = 'F') AND PetID IN (SELECT PetID FROM Pets WHERE PetType = 'Puppy');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT PetType) FROM Pets;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT PetType) FROM Pets;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = 'Cat' OR T3.PetType = 'Dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"kitten\" OR T3.PetType = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT fname FROM student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = 'Kitten') INTERSECT SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = 'Puppy'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"kitten\" INTERSECT SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Major , Age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = \"kitten\"));", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.petid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'dog' AND T3.pettype != 'puppy' GROUP BY T1.stuid;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"puppy\" EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets WHERE birthdate = (SELECT min(birthdate) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets WHERE birthdate = ( SELECT min(birthdate) FROM pets )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01' UNION SELECT petid , weight FROM pets WHERE birthdate > '2020-12-31'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(PetID) , max(PetID) FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(PetID) , max(PetID) FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType, avg(PetID) , max(PetID) FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT PetID FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE LName = 'Smith');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT StuID FROM Student WHERE LName = 'Smith' INTERSECT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT Student.StuID , count(*) FROM Student JOIN Has_Pet ON Student.StuID = Has_Pet.StuID GROUP BY Student.StuID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T2.StuID HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate LIKE \"2001%\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.birthdate LIKE \"2001%\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT stuid FROM has_pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT stuid FROM has_pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id , count(model_list.modelid) FROM car_makers JOIN model_list ON car_makers.id = model_list.maker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id , count(model_list.Maker) FROM car_makers JOIN model_list ON car_makers.id = model_list.Maker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY horsepower ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM model_list ORDER BY maker, model;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM car_names WHERE makeid IN (SELECT id FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data));", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT car_makers.maker FROM car_makers JOIN cars_data ON car_makers.id = cars_data.makeid WHERE cars_data.year >= 2021 AND cars_data.year <= 2022;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT fullname FROM car_makers JOIN cars_data ON car_makers.id = cars_data.makeid WHERE YEAR >= 2022", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT maker , YEAR FROM car_names JOIN cars_data ON car_names.makeid = cars_data.id ORDER BY YEAR ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT car_makers.Maker , cars_data.Year FROM car_makers JOIN cars_data ON car_makers.Id = cars_data.Id ORDER BY cars_data.Year ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT maker FROM model_list WHERE YEAR IN (SELECT YEAR FROM cars_data WHERE YEAR <= 1980)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT model FROM model_list JOIN cars_data ON model_list.id = cars_data.id WHERE cars_data.year <= 1980;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.ContId;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Contid = T2.Continent JOIN car_makers AS T3 ON T2.Countryid = T3.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT countries.CountryName FROM countries JOIN car_makers ON countries.CountryId = car_makers.Country GROUP BY countries.CountryId ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT countryname FROM cars_data GROUP BY country ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , car_makers.fullname FROM car_makers JOIN model_list ON car_makers.id = model_list.maker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , car_makers.id , car_makers.fullname FROM car_makers JOIN model_list ON car_makers.id = model_listmaker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT Accelerate FROM cars_data WHERE Id = (SELECT MakeId FROM car_names WHERE Model = \"amc hornet sportabout (sw)\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT Accelerate FROM cars_data WHERE Id = (SELECT MakeId FROM car_names WHERE Model = \"amc hornet sportabout (sw)\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE Country = 'Japan';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT COUNT(DISTINCT car_makers.Id) FROM car_makers JOIN countries ON car_makers.Country = countries.CountryId WHERE countries.Continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(DISTINCT car_makers.Id) FROM car_makers JOIN countries ON car_makers.Country = countries.CountryId WHERE countries.Continent = 'America';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers JOIN countries ON car_makers.Country = countries.CountryId WHERE countries.Continent = \"Americas\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEar = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEar = 1974;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT Maker FROM car_makers UNION SELECT DISTINCT Maker FROM model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT Maker , Model FROM car_makers JOIN model_list ON car_makers.Id = model_list.Maker;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT DISTINCT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT DISTINCT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(Weight) FROM cars_data GROUP BY YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(Weight), YEAR FROM cars_data GROUP BY YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING count(*) >= 3 INTERSECT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING count(*) >= 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING COUNT(*) >= 3 INTERSECT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = 'Europe' GROUP BY T1.CountryName HAVING COUNT(*) >= 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower), car_names.Make FROM cars_data JOIN car_names ON cars_data.Id = car_names.MakeId WHERE cars_data.Cylinders = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , car_names.Make FROM cars_data JOIN car_names ON cars_data.id = car_names.makeid WHERE cars_data.cylinders = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Id IN (SELECT MakeId FROM car_names WHERE Model = \"tesla\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE cars_data.Id IN (SELECT makeid FROM car_names WHERE makeid NOT IN (SELECT makerid FROM car_makers))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT Accelerate , Cylinders FROM cars_data GROUP BY Cylinders ORDER BY Accelerate DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) FROM cars_data;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT maker , model FROM model_list GROUP BY maker ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Maker , Model FROM model_list GROUP BY Maker , Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers WHERE country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE Country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id FROM car_makers JOIN model_list ON car_makers.id = model_listmaker GROUP BY car_makers.id HAVING count(*) > 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT Maker , Id FROM car_makers WHERE Id IN (SELECT Maker FROM model_list GROUP BY Maker HAVING count(*) > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.modelid = T2.id JOIN car_makers AS T3 ON T1 maker = T3.id WHERE T3.fullname = 'General Motors' OR T2.weight > 3500;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.modelid = T2.id JOIN car_makers AS T3 ON T1.maker = T3.id WHERE T3.maker = 'General Motors' OR T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight < 4000 INTERSECT SELECT YEAR FROM cars_data WHERE Weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Maker = \"tesla\" ORDER BY Accelerate ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT accelerate FROM cars_data ORDER BY horsepower DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT accelerate FROM cars_data ORDER BY horsepower DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT COUNT(DISTINCT country) FROM car_makers WHERE country IN (SELECT country FROM car_makers GROUP BY country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM (SELECT * FROM car_makers GROUP BY Country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE Cylinders = 4 ORDER BY Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE Cylinders = 4 ORDER BY Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT car_names.MakeId , car_names.Make FROM car_names JOIN cars_data ON cars_data.Id = car_names.MakeId WHERE cars_data.Horsepower > (SELECT min(Horsepower) FROM cars_data) AND cars_data.Cylinders > 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT MakeId , model FROM car_names WHERE Id NOT IN (SELECT Id FROM cars_data ORDER BY Horsepower LIMIT 1) AND Cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR Year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR Year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM model_list WHERE maker NOT IN (SELECT Id FROM car_makers WHERE country = 'Ford Motor') AND model NOT IN (SELECT model FROM cars_data WHERE weight > 3500)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.ModelId = T2.Id WHERE T2.Weight < 3500 AND T1.Maker NOT IN (SELECT Id FROM car_makers WHERE car_makers.Country = 'Ford Motor')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker FROM car_makers WHERE id IN (SELECT maker FROM model_list GROUP BY maker HAVING count(*) >= 2 INTERSECT SELECT maker FROM car_makers WHERE id IN (SELECT maker FROM model_list GROUP BY maker HAVING count(*) >= 2))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT Id , Maker FROM car_makers WHERE Id IN (SELECT Maker FROM model_list GROUP BY Maker HAVING COUNT(*) >= 2 INTERSECT SELECT Maker FROM cars_data GROUP BY Maker HAVING COUNT(*) >= 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T3.CountryId , T1.CountryName FROM cars_data AS T3 JOIN car_names AS T4 ON T3.Id = T4.MakeId JOIN countries AS T1 ON T1.CountryId = T2.Country WHERE MakeId = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM cars_data AS T3 JOIN countries AS T1 ON T1.CountryId = T3.Edispl WHERE MakeId = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Abbreviation = 'JET';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = 'JetBlue';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'American';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'American';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Jackson\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Syracuse\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = 'Alton airport';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = 'Alton airport';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Jackson';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Jackson';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = 'ATO';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATO\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE City = \"Jackson\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE City = 'Jackson');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights INNER JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.City = 'Jackson';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport IN (SELECT AirportCode FROM airports WHERE City LIKE '%Jackson%');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports AS source ON flights.SourceAirport = source.AirportCode JOIN airports AS dest ON flights.DestAirport = dest.AirportCode WHERE source.City = 'Syracuse' AND dest.City = 'Ashley';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = (SELECT AirportCode FROM airports WHERE AirportName = \"Syracuse\") AND DestAirport = (SELECT AirportCode FROM airports WHERE AirportName = \"Ashley\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'JetBlue';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'Jetblue';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'JetBlue' AND DestAirport = 'ASY';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = 'ASY' AND Airline = 'JetBlue';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'JetBlue' AND SourceAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'JetBlue' AND SourceAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights INNER JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.City = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'JetBlue' AND DestAirport = (SELECT AirportCode FROM airports WHERE AirportName = 'Aberdeen');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT SourceAirport , COUNT(*) FROM flights GROUP BY SourceAirport ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT City FROM airports JOIN flights ON airports.AirportCode = flights.SourceAirport GROUP BY City ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline GROUP BY T1.Airline ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline GROUP BY T1.Airline ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT Airline FROM flights WHERE SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT Airline FROM flights WHERE SourceAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT Airline FROM flights WHERE DestAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT Airline FROM flights WHERE DestAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = 'APG' INTERSECT SELECT Airline FROM flights WHERE DestAirport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = 'APG' INTERSECT SELECT Airline FROM flights WHERE SourceAirport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = 'CVO' EXCEPT SELECT Airline FROM flights WHERE SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE AirportName = \"CVO\") EXCEPT SELECT Airline FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE AirportName = \"APG\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline HAVING COUNT(*) >= 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline HAVING COUNT(DISTINCT FlightNo) >= 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline HAVING count(*) < 200;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline HAVING count(*) < 200;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = (SELECT AirportCode FROM airports WHERE City = \"Jackson\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = (SELECT AirportCode FROM airports WHERE City = 'Jackson');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = (SELECT AirportCode FROM airports WHERE City = 'Jackson');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport IN (SELECT AirportCode FROM airports WHERE City = 'Syracuse' OR City = 'Jackson') OR SourceAirport IN (SELECT AirportCode FROM airports WHERE City = 'Syracuse' OR City = 'Jackson');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.City = 'Syracuse' OR airports.City = 'Jackson';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights UNION SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportCode FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights UNION SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id, document_name, document_description FROM Documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_id , template_id , document_name , document_description FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE Template_ID IN (SELECT Template_ID FROM Templates WHERE Template_Type_Code = 'PPT');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE Template_ID IN (SELECT Template_ID FROM Templates WHERE Template_Type_Code = 'PPT');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID, COUNT(*) FROM Documents GROUP BY Template_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID, COUNT(*) FROM Documents GROUP BY Template_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_ID IN (SELECT Template_ID FROM Documents GROUP BY Template_ID ORDER BY count(*) DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_ID IN ( SELECT Template_ID FROM Documents GROUP BY Template_ID ORDER BY COUNT(*) DESC LIMIT 1 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT Template_ID FROM Templates WHERE Template_ID NOT IN (SELECT Template_ID FROM Documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT Template_ID FROM Templates WHERE Template_ID NOT IN (SELECT Template_ID FROM Documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To , Template_Type_Code FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To , Template_Type_Code FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = 'PP' OR Template_Type_Code = 'PPT' GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"CV\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = 'CV';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To , Template_Type_Code FROM Templates WHERE Version_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To , Template_Type_Code FROM Templates WHERE Version_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To , COUNT(*) FROM Templates GROUP BY Date_Effective_From , Date_Effective_To;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To , COUNT(*) FROM Templates GROUP BY Date_Effective_From , Date_Effective_To;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From , Date_Effective_To ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From , Date_Effective_To ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From , Date_Effective_To HAVING COUNT(*) < 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From HAVING COUNT(*) < 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Version_Number , Date_Effective_From , Date_Effective_To FROM Templates ORDER BY Version_Number LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates ORDER BY Version_Number LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_ID = (SELECT Template_ID FROM Documents WHERE Document_Name = \"Data base\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_ID IN (SELECT Template_ID FROM Documents WHERE Document_Name = \"Data base\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name , T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM documents WHERE template_id IN (SELECT template_id FROM templates WHERE template_type_code = \"BK\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT Template_Type_Code , Date_Effective_From , Date_Effective_To , COUNT(*) FROM Templates GROUP BY Template_Type_Code , Date_Effective_From , Date_Effective_To;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From , Date_Effective_To ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Date_Effective_From , Date_Effective_To ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_ID NOT IN (SELECT Template_ID FROM Documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_ID NOT IN (SELECT Template_ID FROM Documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = \"Book\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = \"Book\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.Template_Type_Description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Documents AS T3 ON T2.Template_ID = T3.Template_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T2.Template_Details FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Documents AS T3 ON T1.Template_ID = T3.Template_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"Presentation\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = (SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = 'Presentation');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN players AS T3 ON T1.loser_id = T3.player_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT winner_name , loser_name FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT winner_age , loser_age FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT winner_age , loser_age FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name, birth_date FROM players WHERE country_code = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(winner_age) , avg(loser_age) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT tourney_date , tourney_id , YEAR , avg(winner_rank) , avg(loser_rank) FROM matches GROUP BY tourney_date , tourney_id , YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches UNION SELECT avg(loser_rank) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_id HAVING count(*) > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT winner_name , loser_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name , loser_name FROM matches WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT winner_name , loser_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name , loser_name FROM matches WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN players AS T3 ON T1.loser_id = T3.player_id WHERE T1.year = 2013 OR T1.year = 2016;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT winner_name , loser_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT first_name , country_code FROM players WHERE player_id IN ( SELECT winner_id FROM matches WHERE tourney_name = \"WTA Championships\" INTERSECT SELECT winner_id FROM matches WHERE tourney_name = \"Australian Open\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY (SELECT max(birth_date) FROM players) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'Left' ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT t1.first_name , t1.country_code FROM players AS t1 JOIN rankings AS t2 ON t1.player_id = t2.player_id GROUP BY t2.player_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.player_id , T1.first_name , T1.last_name , T1.hand , T1.birth_date , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.player_id , T1.first_name , T1.last_name , T2.ranking_points FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.winner_id = T3.player_id WHERE T3.ranking_points = ( SELECT max(ranking_points) FROM rankings ) AND T1.tourney_name = 'Australian Open' UNION SELECT T1.loser_name , T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id JOIN rankings AS T3 ON T1.loser_id = T3.player_id WHERE T3.ranking_points = ( SELECT max(ranking_points) FROM rankings ) AND T1.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id OR T1.player_id = T2.loser_id WHERE T2.tourney_name = 'Australian Open' AND (T2.winner_rank_points = (SELECT max(t2.winner_rank_points) FROM matches AS T2 WHERE T2.tourney_name = 'Australian Open'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id OR T1.player_id = T2.loser_id ORDER BY T2.minutes DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name , minutes FROM matches JOIN players ON matches.winner_id = players.player_id ORDER BY minutes DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(ranking_points) , t1.player_id , t1.first_name FROM players AS t1 JOIN rankings AS t2 ON t1.player_id = t2.player_id GROUP BY t1.player_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT players.first_name , avg(rankings.ranking) FROM players JOIN rankings ON players.player_id = rankings.player_id GROUP BY players.player_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(loser_rank_points) , T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.player_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.ranking_points) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING COUNT(*) > 50;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING COUNT(*) > 50;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , count(*) FROM rankings GROUP BY ranking_date;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , COUNT(*) FROM rankings GROUP BY ranking_date;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , COUNT(*) FROM matches GROUP BY YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , COUNT(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT winner_id) FROM matches JOIN players ON matches.winner_id = players.player_id WHERE players.hand = 'Left' AND EXISTS (SELECT * FROM matches AS T1 JOIN players AS P1 ON T1.winner_id = P1.player_id WHERE P1.country_code = 'WTA');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = 'left' AND T1.tournament_name = 'WTA Championships';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.winner_id = T3.player_id GROUP BY T3.ranking_points ORDER BY T3.ranking_points DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , COUNT(*) FROM players GROUP BY hand;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , COUNT(*) FROM players GROUP BY hand;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1, line_2, line_3 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 FROM Addresses LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE If_first_show = 'Yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE If_first_show = 'Yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = 'American';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = 'American';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE Type != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE Type != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT COUNT(DISTINCT Nationality) FROM conductor;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT COUNT(DISTINCT Nationality) FROM conductor;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT conductor.Name , orchestra.Orchestra FROM conductor JOIN orchestra ON conductor.Conductor_ID = orchestra.Conductor_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT name FROM conductor WHERE conductor_id IN (SELECT conductor_id FROM orchestra GROUP BY conductor_id HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT name FROM conductor WHERE conductor_id IN (SELECT conductor_id FROM orchestra GROUP BY conductor_id HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.conductor_id FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT conductor.Name , conductor.Conductor_ID FROM conductor JOIN orchestra ON conductor.Conductor_ID = orchestra.Conductor_ID GROUP BY conductor.Conductor_ID ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT conductor.name FROM conductor JOIN orchestra ON conductor.Conductor_ID = orchestra.Conductor_ID ORDER BY orchestra.year_of_founded ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T2.Conductor_ID , T1.Orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE T1.Year_of_Founded = ( SELECT max(Year_of_Founded) FROM orchestra )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE If_first_show = 'Yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE If_first_show = 'Yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE Performance_ID IN (SELECT Performance_ID FROM show GROUP BY Performance_ID HAVING COUNT(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE Orchestra_ID IN (SELECT Orchestra_ID FROM show GROUP BY Performance_ID HAVING COUNT(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs WHERE dog_id IN (SELECT dog_id FROM treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs WHERE dog_id IN (SELECT dog_id FROM treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM professionals WHERE state = 'Indiana' OR professional_id IN (SELECT professional_id FROM treatments GROUP BY professional_id HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM professionals WHERE state = 'Indiana' OR professional_id IN (SELECT professional_id FROM treatments GROUP BY professional_id HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id GROUP BY T1.dog_id HAVING sum(T2.cost_of_treatment) > 1000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Owners UNION SELECT first_name FROM Professionals EXCEPT SELECT name FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , home_phone FROM Treatments GROUP BY professional_id HAVING count(*) >= 2 UNION SELECT professional_id , home_phone FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments GROUP BY professional_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , home_phone , cell_number FROM Professionals WHERE professional_id IN (SELECT professional_id FROM Treatments GROUP BY professional_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM Breeds WHERE breed_code = (SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM breeds JOIN dogs ON dogs.breed_code = breeds.breed_code WHERE abandoned_yn = 'yes' GROUP BY breed_name ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(cost_of_treatment) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM Treatment_Types WHERE treatment_type_code = (SELECT treatment_type_code FROM Treatments GROUP BY treatment_type_code ORDER BY sum(cost_of_treatment) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT Treatment_Types.treatment_type_description FROM Treatment_Types JOIN Treatments ON Treatments.treatment_type_code = Treatment_Types.treatment_type_code GROUP BY Treatments.treatment_type_code ORDER BY sum(cost_of_treatment) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , first_name , last_name FROM Professionals WHERE professional_id IN (SELECT professional_id FROM Treatments GROUP BY professional_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , home_phone , cell_number FROM professionals WHERE professional_id IN (SELECT professional_id FROM treatments GROUP BY professional_id , treatment_type_code HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT DISTINCT T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , Professionals.last_name FROM Treatments JOIN Professionals ON Treatments.professional_id = Professionals.professional_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T.date_of_treatment , Professionals.first_name , Professionals.last_name FROM Treatments AS T JOIN Professionals ON T.professional_id = Professionals.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM Treatments JOIN Treatment_Types ON Treatments.treatment_type_code = Treatment_Types.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T.cost_of_treatment , Treatment_Types.treatment_type_description FROM Treatments AS T JOIN Treatment_Types ON T.treatment_type_code = Treatment_Types.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T2.name , T1.date_of_treatment FROM Treatments AS T1 JOIN Dogs AS T2 ON T1.dog_id = T2.dog_id JOIN Breeds AS T3 ON T2.breed_code = T3.breed_code GROUP BY T2.breed_code ORDER BY count(*) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T1.date_of_birth FROM Dogs AS T1 JOIN Breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.name , T2.first_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_departed - date_arrived FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE abandoned_yn = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE abandoned_yn = 'Y';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM Treatments;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT COUNT(DISTINCT professional_id) FROM Treatments WHERE dog_id IN (SELECT dog_id FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT last_name , first_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name, last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 'Y' AND age < (SELECT avg(age) FROM Dogs);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 'Y' AND age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 'Y' AND dog_id NOT IN (SELECT dog_id FROM Treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM Treatments;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE abandoned_yn = 'yes');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE abandoned_yn = '1');", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 'Y';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = 'yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type, charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charge_amount) FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM Charges ORDER BY charge_amount DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address, first_name, last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_code , size_code FROM Dogs UNION SELECT breed_code , size_code FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT breed_code , size_code FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T Professionals.first_name , T Professionals.last_name , T Treatments.treatment_type_description FROM Professionals JOIN Treatments ON Professionals.professional_id = T Treatments.professional_id JOIN Treatment_Types ON T Treatments.treatment_type_code = Treatment_Types.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T.professional_id , Professionals.first_name , Professionals.last_name , Treatment_Types.treatment_type_description FROM Treatments AS T INNER JOIN Professionals ON T.professional_id = Professionals.professional_id INNER JOIN Treatment_Types ON T.treatment_type_code = Treatment_Types.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship, COUNT(*) FROM singer GROUP BY Citizenship;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT Title FROM song ORDER BY Sales DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT Title FROM song ORDER BY Sales DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(DISTINCT T2.Title) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT name FROM singer WHERE singer_id IN (SELECT singer_id FROM song GROUP BY singer_id HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T1.Name , MAX(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT name , max(highest_position) FROM singer AS t1 JOIN song AS t2 ON t1.singer_id = t2.singer_id GROUP BY t1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT title FROM song WHERE song_id NOT IN (SELECT song_id FROM song GROUP BY song_id HAVING COUNT(DISTINCT singer_id) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945 GROUP BY Citizenship HAVING COUNT(*) >= 2", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_dk/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_dk/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..3242a68c79c99ae41231d0bcf6e66b0eb1aa70a6 --- /dev/null +++ b/infer/qwen/spider_dk/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5887 @@ +[ + { + "sample_id": "spider_dk:test:0", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:1", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the total number of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:2", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show name, country for all singers ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY Birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:3", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, countries for every singer in descending order of age?", + "gold_sql": "SELECT name , country FROM singer ORDER BY birthday ASC", + "pred_sql": "SELECT name , country FROM singer ORDER BY birthday DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:4", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id of all French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:5", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average, minimum, and maximum id for French singers?", + "gold_sql": "SELECT avg(Singer_ID) , min(Singer_ID) , max(Singer_ID) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(singer_id) , min(singer_id) , max(singer_id) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:6", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:7", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday desc LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY birthday LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:8", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all distinct countries where singers born in 2001 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Birthday = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:9", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the different countries with singers born in 2001?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE birthday like '2001%'", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE birthday = 2001", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:10", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show all countries and the number of singers in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:11", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many singers are from each country?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:12", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all song names by singers above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:13", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE birthday < (SELECT avg(birthday) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE birthday > (SELECT avg(birthday) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:14", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show location and name for all stadiums with a capacity between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:15", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the locations and names of all stations with capacity between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:16", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and the highest capacity of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:17", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the average and highest capacities for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:18", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:19", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and capacity for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:20", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts are there after or in year 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:21", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "How many concerts occurred after or in 2014?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:22", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and the number of concerts in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:23", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "For each stadium, how many concerts play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.stadium_id FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:24", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:25", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and highest attendance of the stadium with the most concerts after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.highest FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:26", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Which concert is the oldest?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:27", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Return the oldest concert name?", + "gold_sql": "SELECT concert_Name FROM concert ORDER BY YEAR asc LIMIT 1", + "pred_sql": "SELECT concert_Name FROM concert ORDER BY YEAR LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:28", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the highest attendance without any concert.", + "gold_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT highest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:29", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are lowest attendance of the stadiums without any concerts?", + "gold_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:30", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show countries where a singer born in 1981 or 1991 are from.", + "gold_sql": "SELECT country FROM singer WHERE birthday like '1981%' or birthday like '1991%'", + "pred_sql": "SELECT Country FROM singer WHERE Birthday = \"1981\" OR Birthday = \"1991\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:31", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show average attendance for all stadiums except for stadiums having a concert in year 2014.", + "gold_sql": "SELECT average FROM stadium EXCEPT SELECT T2.average FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT avg(Average) FROM stadium WHERE Stadium_ID NOT IN (SELECT T1.Stadium_ID FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID WHERE T1.year = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:32", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest attendance of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT lowest FROM stadium EXCEPT SELECT T2.lowest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT lowest FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:33", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each concert.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:34", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names, themes, and number of singers for each and every concert?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.Name , T1.Theme , COUNT(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:35", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List singer names and number of concerts for each singer.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:36", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer_as_i_concert T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN singer_in_concert AS T3 ON T1.concert_id = T3.concert_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:37", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "List all singer names in concerts after or in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year >= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year >= 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:38", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the names of the singers who performed in a concert before or in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year <= 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year < 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:39", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its name?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:40", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:41", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the lowest and highest attendance of the stadiums which some concerts happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(t1.lowest) , max(t1.lowest) , min(t1.lowest) , min(t1.lowest) FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year = 2014 INTERSECT SELECT max(t1.lowest) , max(t1.lowest) , min(t1.lowest) , min(t1.lowest) FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:42", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the lowest and highest attendance of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.lowest , T2.highest FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT max(t1.lowest) , min(t1.lowest) FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT max(t1.lowest) , min(t1.lowest) FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:43", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "Find the number of concerts happened in the stadium with the highest capacity.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T1.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:44", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_concert_singer", + "question": "What are the number of concerts that occurred in the stadium with the largest capacity?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:45", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets whose weight is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:46", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets have a greater weight than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:47", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:48", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:49", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the maximum weight for each type of pet. List the maximum weight and pet type.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:50", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "List the maximum weight and type for each type of pet.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:51", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:52", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many pets are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:53", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of puppy pets that are raised by female students (with sex F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T1.sex = 'F' AND T3.pettype = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:54", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many puppy pets are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:55", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of distinct type of pets.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:56", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "How many different types of pet are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:57", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:58", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the first names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:59", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name of students who have both Kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T3.PetID = T2.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T3.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:60", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the students' first names who have both kitten and puppy as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:61", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:62", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What major is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:63", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:64", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:65", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and age of students who have a dog but do not have a puppy as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:66", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name of every student who has a puppy but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:67", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY birthdate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:68", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY birthdate desc LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets ORDER BY birthdate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:69", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id and weight of all pets older than that born in 2020.", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-01-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > \"2020-01-01\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:70", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id and weight of every pet who is older than that born in 2020?", + "gold_sql": "SELECT petid , weight FROM pets WHERE birthdate < '2020-05-01'", + "pred_sql": "SELECT petid , weight FROM Pets WHERE birthdate > '2020-'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:71", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each type of pet.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(PetID) , max(PetID) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:72", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average and maximum id for each pet type?", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:73", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average and maximum id for each pet type.", + "gold_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(PetID) , max(PetID) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:74", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average weight for each type of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:75", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.petid IN (SELECT petid FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:76", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What are the different names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.LName T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:77", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the id of the pet owned by student whose last name is ‘Smith’.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.PetID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:78", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the id of the pet owned by the student whose last name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.PetID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:79", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the number of pets for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:80", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "For students who have pets, how many pets does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:81", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the first name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Fname , T2.Sex FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:82", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the first name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:83", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the last name of the student who has a cat that born in 2001.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.Lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.birthdate = \"2001\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:84", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the last name of the student who has a cat that born in 2001?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.birthdate like '2001%' AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Pets AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.birthdate = \"2001-04-15\" AND T1.pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:85", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:86", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:87", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:88", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:89", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries does each continent have? List the continent id, continent name and the number of countries.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:90", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many countries it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:91", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:92", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:93", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car maker produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:94", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car maker, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:95", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model of the car has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.MakeId ORDER BY T2.Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:96", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the car with the smallest amount of horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:97", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car whose weight is below the average weight.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:98", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:99", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE YEAR > 2019 UNION SELECT T2.Maker FROM cars_data AS T2 JOIN car_makers AS T1 ON T1.id = T2.model WHERE YEAR > 2019", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:100", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in the past two years?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year >= '2019';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.modelid WHERE T2.year < 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:101", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.Year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:102", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T1.Year FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T2.model = 'Carr' ORDER BY T1.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:103", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T1.fullname FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN car_names AS T3 ON T2.model = T3.model WHERE T3.year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:104", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced before or in 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year <= 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.year <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:105", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT count(*) , T1.Continent FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:106", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many car makers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:107", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which of the countries has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryID GROUP BY T2.Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:108", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the country with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T2.Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:109", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each maker? List the count and the maker full name.", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:110", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each maker and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Id , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:111", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the car make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"amc\" AND model = \"horseport sportabout\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:112", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How much does the car accelerate that makes amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.MPG FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model WHERE T3.Maker = 'AMC Hornet Sportabout' AND T1.Accelerate = 'Fast'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:113", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many Japanese car makers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = 'Japan'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:114", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of Japanese care?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'Japan';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers WHERE maker = \"Japanese care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:115", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the america?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN country AS T2 ON T1.country = T2.countryid WHERE T2.contname = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:116", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:117", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:118", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cards with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:119", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT Weight FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:120", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 4 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:121", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are all the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:122", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the makers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:123", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the countries having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T2.Id FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:124", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all countries with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T1.CountryId HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:125", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with horsepower more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:126", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a horsepower greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:127", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of cars each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:128", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:129", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which European countries have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = \"European\" GROUP BY T1.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:130", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" GROUP BY T2.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:131", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum horsepower and the make of the car models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Make FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:132", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of horsepower for the models with 3 cylinders and what make is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T2.cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:133", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:134", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT t1.model FROM car_makers AS t1 JOIN car_names AS t2 ON t1.id = t2.makeid JOIN cars_data AS t3 ON t2.model = t3.model WHERE t3.mpg = (SELECT max(mpg) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:135", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:136", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before or in 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR <= 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:137", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of model tesla?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = 'Tesla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:138", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all teslas?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'tesla';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:139", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT Accelerate , Cylinders FROM cars_data GROUP BY Cylinders ORDER BY max(Accelerate) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:140", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:141", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of cars?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.maker FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = (SELECT t3.make FROM cars_data AS t3 GROUP BY t3.make ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:142", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model GROUP BY T1.Maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:143", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:144", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:145", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in the last two years?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR >= 2023 AND YEAR < 2024", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:146", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In the last two years, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR >= 2019;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR < 2022 AND YEAR > 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:147", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(DISTINCT t1.models) FROM model_list AS t1 JOIN car_makers AS t2 ON t1.maker = t2.id JOIN cars_data AS t3 ON t3.id = t2.make WHERE t2.fullname = \"American Motor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:148", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:149", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which makers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:150", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all makers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:151", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by maker with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN car_names AS T3 ON T3.makeid = T2.model WHERE T1.fullname = \"General Motors\" OR T3.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:152", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car maker General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.models FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id WHERE T2.fullName = \"General Motors\" UNION SELECT DISTINCT T3.models FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id JOIN cars_data AS T3 ON T3.id = T1.model WHERE T3.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:153", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:154", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced that weighed less than 4000 and also cars that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE Weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:155", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:156", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the horsepower of the car with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:157", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For model tesla, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(cylinders) FROM cars_data WHERE model = 'Tesla' AND accelerate = (SELECT min(accelerate) FROM cars_data WHERE model = 'Tesla')", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:158", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For a tesla model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'tesla' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND make = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:159", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars have a larger accelerate than the car with the largest horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:160", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with a greater accelerate than the one with the most horsepower?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:161", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many countries has more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:162", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of countries with more than 2 car makers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:163", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "How many cars has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:164", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the number of carsw ith over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:165", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For the cars with 4 cylinders, which model has the largest horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:166", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.id = t2.makeid WHERE t1.cylinders = 4 GROUP BY t2.model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:167", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars with more than lowest horsepower, which ones do not have more than 3 cylinders? List the car makeid and make name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders != 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:168", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Among the cars that do not have the minimum horsepower, what are the make ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM cars_data WHERE horsepower NOT IN (SELECT min(horsepower) FROM cars_data) GROUP BY makeid HAVING cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:169", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the car with 8 cylinders or produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:170", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the cars that had 8 cylinders or that were produced before or in 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR <= 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR <= 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:171", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T1.fullname = 'Ford Motor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:172", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.makeid = T2.id WHERE T1.maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:173", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the countries where there is not a single car maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:174", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the countries with no car makers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries WHERE CountryId NOT IN (SELECT Country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:175", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "Which are the car makers which produce at least 2 models and more than 3 car makes? List the id and the maker.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.makeer FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.makeer FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:176", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and makers of all car makers that produce at least 2 models and make more than 3 cars?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make GROUP BY T1.id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:177", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'tesla' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE T2.maker = 'Tesla' UNION SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country GROUP BY T1.countryid HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:178", + "benchmark": "spider_dk", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce teslas?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'tesla';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker > 3 UNION SELECT CountryId , CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:179", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which country does Airline \"JetBlue\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:180", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:181", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of Airline \"JetBlue\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:182", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to JetBlue?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:183", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List all american airline names and their abbreviations.", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:184", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are american airline names and abbreviations for airlines?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:185", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Jackson.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Jackson\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:186", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the Syracuse.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Syracuse\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Syracuse'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:187", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:188", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the total number of airlines?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:189", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airports do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:190", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airports.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:191", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:192", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:193", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has abbreviation 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:194", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:195", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from America?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:196", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the America.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:197", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city and country is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:198", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the city and country for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:199", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:200", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the airport with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:201", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at 'Jackson'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:202", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Jackson?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Jackson\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:203", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:204", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceAirport = T2.airportCode WHERE T2.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:205", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have destination ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:206", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:207", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Jackson?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:208", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceAirport = T2.airportCode WHERE T2.airportname = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:209", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Jackson city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:210", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Jackson.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:211", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Syracuse' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' AND T1.airline = 'FLX' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:212", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Syracuse to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Syracuse\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Syracuse\" INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:213", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airline 'JetBlue' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.Uid WHERE T2.Aline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:214", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'Jetblue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:215", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'ASY' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:216", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY Airport\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:217", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many 'JetBlue' flights depart from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:218", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of JetBlue flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"JetBlue Airways\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\" AND T1.Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:219", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many JetBlue flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 'JetBlue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:220", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of JetBlue flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\" AND T1.airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:221", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:222", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has the most frequent destination airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:223", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:224", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which city is the most frequent source airport?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:225", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.destairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:226", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the airport code of the airport with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:227", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of airport that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:228", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the airport with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T2.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:229", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airline has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT airline FROM flights GROUP BY airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:230", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What airline serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:231", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the abbreviation and country of the airline that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.Ui = T2.airline GROUP BY T2.airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:232", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of the airilne has the fewest flights and what country is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline GROUP BY T2.Airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:233", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:234", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:235", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:236", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight with destination airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T3.AirportCode = T2.DestAirport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:237", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both airports 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:238", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:239", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:240", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T1.Abbreviation = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T1.Abbreviation = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:241", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:242", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:243", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT airline FROM flights GROUP BY airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:244", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline GROUP BY T1.Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:245", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers belonging to \"JetBlue\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:246", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to JetBlue flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"JetBlue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:247", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:248", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:249", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:250", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:251", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:252", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:253", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at \"Jackson\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:254", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Jackson.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Jackson\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:255", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in the Syracuse or Jackson.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Syracuse' OR T2.city = 'Jackson'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:256", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Syracuse or Jackson?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Syracuse\" OR T2.city = \"Jackson\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Syracuse\" OR T2.City = \"Jackson\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:257", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , srcairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:258", + "benchmark": "spider_dk", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportcode FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights , flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.abbreviation WHERE T1.airline = \"Airline X\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:259", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:260", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM DOCUMENTS", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:261", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List document IDs with its names and descriptions.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:262", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all the ids with its names and descriptions for all documents?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:263", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the name with template id of documents with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:264", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names with document and template ids for documents that contain the letter w in their description.", + "gold_sql": "SELECT document_name , Document_ID, template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , template_id FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:265", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the description for document named \"Robbin CV\" with its document and template id?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , document_id , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:266", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the description with document and template id of the document with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT document_description , template_id FROM Documents WHERE document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:267", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different templates do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:268", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different templates used for documents.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_id) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:269", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many documents are using the PPT template?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:270", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of documents that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:271", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template ids and the number of documents using each template.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:272", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different template ids used for documents, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:273", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period for the template used by the most documents?", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:274", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used for the greatest number of documents.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:275", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates that are used by more than one document.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:276", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single document?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:277", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any document.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT template_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:278", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for templates that are not used in any documents?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT template_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:279", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many templates do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:280", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of templates.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:281", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show effective date period, and template type codes for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT Date_Effective_From , Template_Type_Code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:282", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and type codes for each template?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:283", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period for all templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Date_Effective_To > Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:284", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT date_Effective_from , date_Effective_to FROM Templates WHERE date_Effective_to - date_Effective_from >= 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:285", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range with template type code PP or PPT?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:286", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range that have the code PP or PPT.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:287", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give me the effective date period whose template type code is CV?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:288", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period of the template type CV.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:289", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date period and template type code for the template with version number later than 5?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT date_effective_from , template_type_code FROM Templates WHERE version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:290", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period and template type codes of templates with a version number greater than 5.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Date_Effective_From , template_type_code FROM Templates WHERE VERSION_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:291", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period and number of templates for each.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:292", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period, and how many templates correspond to each?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Date_Effective_From , count(*) FROM Templates GROUP BY Date_Effective_From", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:293", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period has most number of templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:294", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that the most templates belong to.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:295", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date period with less than three templates.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:296", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date period that have fewer than 3 templates?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:297", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest version number and its effective date date from and to?", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:298", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest version number, along with its corresponding effective date date from and to.", + "gold_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates", + "pred_sql": "SELECT min(Version_Number) , Date_Effective_From , Date_Effective_To FROM Templates GROUP BY Version_Number", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:299", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the effective date range of the template used by document with the name \"Data base\"?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:300", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date range of the template that is used by a document named Data base.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:301", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all document names along with document and template id using templates with template type code BK.", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name , template_id FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:302", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names of documents with document and template id that use templates with the code BK?", + "gold_sql": "SELECT T2.document_name, T2.Document_ID, T2.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM documents AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:303", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to, and the number of documents using each type.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T2.date_effective_from , count(*) , T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:304", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are effective date from and to, and how many documents use each type?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.date_effective_from , T1.date_effective_to , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from , T1.date_effective_to", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:305", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which effective date period is used by most number of documents?", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.date_effective_from FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.date_effective_from ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:306", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period that is most commonly used in documents.", + "gold_sql": "SELECT T1.Date_Effective_From , T1.Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Date_Effective_From FROM Templates GROUP BY Date_Effective_From ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:307", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all effective date from and to that are not used by any document.", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:308", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date from and to that are not used for any document?", + "gold_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates EXCEPT SELECT Date_Effective_From , Date_Effective_To FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT date_effective_from , date_effective_to FROM Templates EXCEPT SELECT T1.date_effective_from , T1.date_effective_to FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:309", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all template type codes and descriptions.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:310", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type codes and descriptions for all template types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:311", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type descriptions for template type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Ref_Template_Types.template_type_description FROM Ref_Template_Types WHERE Ref_Template_Types.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:312", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the template type description of the template type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:313", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the template type code for template type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:314", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type code of the template type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:315", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct template type descriptions for the templates ever used by any document?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:316", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different descriptions for templates that have been used in a document.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:317", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the effective date range from to with template type description \"Presentation\".", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From , Date_Effective_To FROM Templates WHERE Template_Type_Code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:318", + "benchmark": "spider_dk", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the effective date period corresponding to templates with the description 'Presentation'.", + "gold_sql": "SELECT T2.Date_Effective_From , T2.Date_Effective_To FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Date_Effective_From FROM Templates WHERE Template_Type_Code = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:319", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player names in each match.", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:320", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player names in each match?", + "gold_sql": "SELECT loser_name, winner_name FROM matches", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:321", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T2.losing_age FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:322", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Give me both player ages in each match.", + "gold_sql": "SELECT winner_age, loser_age FROM matches", + "pred_sql": "SELECT T1.loser_age FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:323", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all American players.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:324", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of American players?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:325", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average loser and winner age of all matches.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT loser_age , winner_age FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:326", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the average loser and winner ages across matches?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:327", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find their all average rank including winner and loser in each matches.", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT winner_rank , loser_rank FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:328", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for all players including winner and loser in all matches?", + "gold_sql": "SELECT avg(winner_rank), avg(loser_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) + avg(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:329", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of all players including winner and loser in all matches.", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(T2.ranking) FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id UNION SELECT max(T2.ranking) FROM matches AS T1 JOIN rankings AS T2 ON T1.loser_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:330", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of all players including winner and loser across all matches?", + "gold_sql": "SELECT min(winner_rank), min(loser_rank) FROM matches", + "pred_sql": "SELECT max(winner_rank) , max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:331", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct country codes of all players.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:332", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct countries do players come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:333", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:334", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:335", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tourney that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:336", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:337", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all match players including winner and loser who played in both 2013 and 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:338", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all match players including winner and loser who played in both 2013 and 2016?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT loser_name, winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:339", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the all player name in each matche who played in years of 2013 or 2016.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 OR T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:340", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, Give me all player name of each matche in 2013 or 2016 year?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 OR T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:341", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:342", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:343", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:344", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:345", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players order of their birth date from old to young.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:346", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted from oldest to youngest?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:347", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left / L hand in the order of their date of birth from the oldest to the youngest.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:348", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the name of all left handed players, in order of date of birth from the young to the old?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date desc", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:349", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the player who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:350", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the player with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:351", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of matches.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:352", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most matches?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:353", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the player who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:354", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:355", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find all match player name including winner and loser where the winner has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tournament_name = 'Australian Open tourney' ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:356", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the match player names including winner and loser where the winner had the most rank points and participated in the Australian Open tournament?", + "gold_sql": "SELECT loser_name, winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T2.player_id = T3.player_id WHERE T1.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:357", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Including winner and loser, find all the player names in each match with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.loser_name ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:358", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "In each match, what are the winner with loser names who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:359", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each player and their first name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:360", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names of all players, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:361", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each player and their name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name , T2.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:362", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of all players, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name, T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:363", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each country.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:364", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each country?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:365", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the country where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:366", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the country with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:367", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of countries that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:368", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of countries with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:369", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of tours for each ranking date.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:370", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many total tours were there for each ranking date?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_date , sum(tours) FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:371", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of matches happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:372", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:373", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year , T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:374", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:375", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"wta\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:376", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:377", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and birth date of the winner who has the highest rank points in all matches.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:378", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "What is the name and birth date of the player with the most winner rank points across all matches?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:379", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of players for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:380", + "benchmark": "spider_dk", + "split": "test", + "db_id": "wta_1", + "question": "How many players are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:381", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:382", + "benchmark": "spider_dk", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Give me the three addresse lines?", + "gold_sql": "SELECT line_1 , line_2, line_3 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 , line_3 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:383", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many first shows?", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:384", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of first show.", + "gold_sql": "SELECT count(*) FROM show where If_first_show = 'T'", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:385", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:386", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday desc", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:387", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of american conductors?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:388", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the names of american conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality = 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:389", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies of orchestras in the order of founded years from oldest to latest?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:390", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the record companies of orchestras, sorted by the founded year from oldest to latest.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:391", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the average attendance of non-first shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:392", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the average attendance across all non-first shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW where If_first_show = 'F'", + "pred_sql": "SELECT avg(Attendance) FROM show WHERE If_first_show = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:393", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:394", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Return the maximum and minimum shares for performances that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:395", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many different nationalities do conductors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:396", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of different nationalities of conductors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:397", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List names of conductors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:398", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors, sorted ascending by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY birthday DESC", + "pred_sql": "SELECT Name FROM conductor ORDER BY birthday ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:399", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the name of the conductor with the longest work.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:400", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has worked the longest?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:401", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors and the orchestras they have conducted.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.Name , T1.Orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:402", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors as well as the corresonding orchestras that they have conducted?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:403", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the names of conductors that have conducted more than one orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:404", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted at more than one orchestra?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:405", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the name of the conductor that has conducted the most number of orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:406", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the name of the conductor who has conducted the most orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:407", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the name of the conductor who has conducted the oldest orchestras.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded asc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:408", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the names of conductors who have conducted the latest orchestras?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID order by Year_of_Founded desc limit 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id ORDER BY T2.year_of_founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:409", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the different record companies and the corresponding number of orchestras.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:410", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "How many orchestras does each record company manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , count(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:411", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Please show the record formats of orchestras in ascending order of age.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT Major_record_format FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:412", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the major record formats of orchestras, sorted by their age?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra ORDER BY Year_of_Founded desc", + "pred_sql": "SELECT major_record_format FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:413", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the record company shared by the oldest orchestras.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded asc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE YEAR_of_Founded = (SELECT min(YEAR_of_Founded) FROM orchestra)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:414", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What is the record company used by the newest orchestras?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded desc LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:415", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "List the names of orchestras that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:416", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the orchestras that do not have any performances?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:417", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the record companies shared by orchestras founded before or in 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded <= 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM performance WHERE TYPE = \"Show\" AND YEAR_OF_FOUNDED < 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:418", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are the record companies that are used by both orchestras founded after or in 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded >= 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003 GROUP BY Record_Company HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:419", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Find the number of first shows in \"Glebe Park\".", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE IF_first_show = 'Yes' AND Performance_ID IN (SELECT Performance_ID FROM show WHERE RESULT = \"Glebe Park\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:420", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Count the number of all first shows in \"Glebe Park\"", + "gold_sql": "SELECT COUNT(*) FROM show WHERE Result = \"Glebe Park\" and If_first_show = \"T\"", + "pred_sql": "SELECT count(*) FROM show WHERE if_first_show = 'yes' AND performance_id IN (SELECT Performance_ID FROM performance WHERE TYPE = \"Glebe Park\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:421", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "Show the type in which performance that have given more than one non-first show.", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID WHERE If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id IN (SELECT Performance_ID FROM show WHERE If_first_show = 1 EXCEPT SELECT Performance_ID FROM performance GROUP BY Performance_ID HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:422", + "benchmark": "spider_dk", + "split": "test", + "db_id": "new_orchestra", + "question": "What are type of performances that have had more than one non-first show?", + "gold_sql": "SELECT Type FROM performance AS T1 JOIN show AS T2 ON T1.Performance_ID = T2.Performance_ID Where If_first_show = 'F' GROUP BY T2.Performance_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT TYPE FROM performance WHERE performance_id NOT IN (SELECT performance_id FROM show WHERE if_first_show = 'yes') GROUP BY TYPE HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:423", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both owners and professionals living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:424", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both owners and professionals live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:425", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any treatments?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:426", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through treatments.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:427", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in the state of Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:428", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in the state of Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT DISTINCT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT DISTINCT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2 AND T1.state = 'Indiana'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:429", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their owner more than 1000 for treatment? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:430", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:431", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for professionals or owners but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals EXCEPT SELECT T1.first_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:432", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for professionals or owners but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals EXCEPT SELECT T1.first_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:433", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professional did not operate any treatment on dogs? List the professional's id, and name.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals EXCEPT SELECT T1.professional_id , T2.first_name , T2.last_name FROM professionals AS T1 JOIN owners AS T2 ON T1.professional_id = T2.owner_id JOIN dogs AS T3 ON T3.owner_id = T2.owner_id WHERE T3.gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:434", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, and name of the professionals who did not perform any treatment on dogs.", + "gold_sql": "SELECT professional_id , first_name , last_name FROM Professionals EXCEPT SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , first_name , last_name FROM professionals EXCEPT SELECT T1.professional_id , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T1.dog_id = T3.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:435", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner owns the most dogs? List the owner id, and name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:436", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the owner id and name of the owner who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T1.first_name , T1.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:437", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two treatments? List the professional's id, home and phone number.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:438", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, home and phone number of the professionals who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.home_phone FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:439", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most abandoned dogs?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T2.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:440", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most abandoned dogs have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code where abandoned_yn = 1 GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.abandoned_yn = '1' GROUP BY T2.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:441", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid for the most treatments on his or her dogs? List the owner id and last name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:442", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the owner id and last name of the owner who spent the most on treatments of his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:443", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treats AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:444", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type_code GROUP BY T1.treatment_type_code ORDER BY sum(T2.charge_amount) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:445", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owner has paid the largest amount of money in total for their dogs? Show the owner id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.abandoned_yn) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:446", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the owner id and zip code of the owner who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:447", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have done at least two types of treatments? List the professional id and name.", + "gold_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:448", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and home and phone number of the professionals who operate two or more types of treatments.", + "gold_sql": "SELECT T1.professional_id , T1.home_phone , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name , T1.home_phone , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:449", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the name of the professionals who have done treatment with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:450", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that costs less than the average? Give me their names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:451", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each treatment, together with the name of the professional who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:452", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating professional's name of each treatment?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T2.date_of_treatment , T3.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T3.professional_id JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code WHERE T3.treatment_type_description = \"Pet Treat\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:453", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each treatment and the corresponding treatment type description.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:454", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and treatment type description of each treatment?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:455", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each owner's name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.size FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:456", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.weight FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:457", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the owner's names and the dogs's name.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:458", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each owner's name and their dogs's name?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:459", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the dogs of the rarest breed and the treatment dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T3.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN professionals AS T3 ON T2.professional_id = T3.professional_id WHERE T1.gender = 'dog' AND T3.role_code = 'Veterinarian' AND T2.treatment_type_code = 'Surgical' ORDER BY T1.breed_code , T3.date_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:460", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and treatment dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:461", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in VA? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:462", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in VA and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:463", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the treatment date from dog arriving to departing?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:464", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the dog treatment period from arriving to departing date.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:465", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:466", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:467", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in the state of HI or WI.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:468", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either the state of HI or WI?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"HI\" OR state = \"WI\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:469", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving date and the departing date of all the abandoned dogs?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:470", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arrival date and the departure date for all the abandoned dogs.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:471", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs went through any treatments?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:472", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that went through a treatment.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = 'Dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:473", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals have performed any treatment to dogs?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.professional_id) FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.treatment_type_code = \"therapy\" OR T1.treatment_type_code = \"medicine\" OR T1.treatment_type_code = \"surgery\" OR T1.treatment_type_code = \"extraction\" OR T1.treatment_type_code = \"cure\" OR T1.treatment_type_code = \"recovery\" OR T1.treatment_type_code = \"pound\" OR T1.treatment_type_code = \"recovery\" OR T1.treatment_type_code = \"therapy\" OR T1.treatment_type_code = \"medicine\" OR T1.treatment_type_code = \"surgery\" OR T1.treatment_type_code = \"extraction\" OR T1.treatment_type_code = \"cure\" OR T1.treatment_type_code = \"recovery\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:474", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have ever treated dogs.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.professional_id) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:475", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in a city containing the substring 'West'? List his or her name.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:476", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the name of the professionals living in a city that contains the substring 'West'.", + "gold_sql": "SELECT first_name , last_name FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT first_name , last_name FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:477", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Which owners live in the state whose name contains the substring 'North'? List his name.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:478", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the name of the owners living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:479", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:480", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of abandoned dogs of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs) AND abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:481", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent treatment cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:482", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:483", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many abandoned dogs have not gone through any treatment?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE abandoned_yn = 1 and dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments ) AND abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:484", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of dogs that have received any treatment.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:485", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many owners temporarily do not have any abandoned dogs?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(DISTINCT owner_id) FROM dogs WHERE abandoned_yn = 'yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:486", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of owners who do not own any abandoned dogs at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs where abandoned_yn = 1 )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE abandoned_yn = 'yes' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:487", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How many professionals did not operate any treatment on dogs?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = \"dog\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:488", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of professionals who have not treated any dogs.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = \"dog\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:489", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the abandoned dogs? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:490", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:491", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the abandoned dogs?", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:492", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the abandoned dogs.", + "gold_sql": "SELECT avg(age) FROM Dogs where abandoned_yn = 1", + "pred_sql": "SELECT avg(age) FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:493", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest dog?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:494", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest dog.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:495", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:496", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:497", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:498", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:499", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email and name of all the professionals.", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals WHERE role_code = 'Professional'", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:500", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, and name of each professional?", + "gold_sql": "SELECT email_address , first_name , last_name FROM professionals", + "pred_sql": "SELECT email_address , first_name , last_name FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:501", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_type , T2.size_type FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:502", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for dogs.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:503", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "List the name of all the professionals along with the description of the treatment they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.role_code , T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:504", + "benchmark": "spider_dk", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each professional's name and description of the treatment they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:505", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "How many singers are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:506", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the count of singers?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:507", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of age.", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:508", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year desc", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:509", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and citizenship of singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:510", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and citizenships of the singers?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:511", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers who is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:512", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:513", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers whose birth year is earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:514", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers whose birth years are earlier than or in 1948?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year <= 1948", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:515", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the youngest age?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:516", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer who is the youngest?", + "gold_sql": "SELECT Name FROM singer ORDER BY Birth_Year DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Birth_Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:517", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of singers and the number of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:518", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, how many singers are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:519", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Please show the most common citizenship of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:520", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the msot common singer citizenship?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:521", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show different citizenships and the highest net worth of singers of each citizenship.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:522", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each citizenship, what is the highest net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:523", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of the highest sales songs.", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY sales DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:524", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are names of the highest sales songs?", + "gold_sql": "SELECT Title FROM song order by Sales desc limit 1", + "pred_sql": "SELECT title FROM song ORDER BY highest_position DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:525", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:526", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:527", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:528", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:529", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the names of singers and the max highest position of their songs.", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:530", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "For each singer name, what is the maximum highest position for their songs?", + "gold_sql": "SELECT T1.Name , max(T2.Highest_Position) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , max(T1.Highest_Position) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:531", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "List the name of singers that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:532", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What is the sname of every sing that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Name NOT IN (SELECT T3.Singer_ID FROM song AS T3 ON T3.Singer_ID = T1.Singer_ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:533", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers with birth year before or in 1945.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "success": true, + "error": null + }, + { + "sample_id": "spider_dk:test:534", + "benchmark": "spider_dk", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers with a birth year before or in 1945?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year <= 1945", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..65f71e889afb85dd820a2309771d28cddcc1062d --- /dev/null +++ b/infer/qwen/spider_realistic/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.name , t2.capacity FROM concert AS t1 JOIN stadium AS t2 ON t1.stadium_id = t2.stadium_id WHERE t1.year >= 2014 GROUP BY t1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year > 2013 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_name , T1.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.Year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.average > (SELECT max(average) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.average > (SELECT avg(average) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T2.pettype = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Cat\") INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Dog\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE pettype = \"Cat\" INTERSECT SELECT PetID FROM Pets WHERE pettype = \"Dog\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_id NOT IN (SELECT PetID FROM Pets WHERE pet_age > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE Pet = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT PetType , pet_age FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.year FROM cars_data AS T1 JOIN car_names AS T2 ON T1.id = T2.model WHERE T1.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T1.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = (SELECT T3.Maker FROM car_makers AS T3 GROUP BY T3.Maker ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'AMC Hornet Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'Toyota' AND T1.country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T2.Id FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker != \"Unknown\" GROUP BY T2.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T1.CountryId HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country == T2.CountryID GROUP BY T1.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.MPG > 30;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY avg(mpg) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.FullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model GROUP BY T1.Model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.FullName , T1.Id FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T1.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.weight > 3500 OR T1.Maker = 'General Motors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE WEIGHT BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(cylinders) FROM cars_data WHERE make = 'volvo' ORDER BY accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.Cylinders = 4 GROUP BY T1.Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.fullname = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT model FROM car_makers", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId GROUP BY T1.CountryID HAVING COUNT(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = 'fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'Ford' UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'BMW'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE Abbreviation = \"JetBlue Airways\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE country = 'United Kingdom'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T2.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" AND T1.DestAirport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Ashley\" AND T1.DestAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Aline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Aline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abnovation = 'United Airlines' INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T3.Abbreviation = 'ASY' WHERE T3.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abnovation = 'United Airlines' AND T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abnovation = \"United\" AND T1.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen' AND T1.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\" AND T1.airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'CVO' EXCEPT SELECT DISTINCT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FLIGHTNO FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT flightno FROM flights JOIN airlines ON flights.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = 'Aberdeen' OR T2.City = 'Abilene'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT Manager_name , district FROM shop ORDER BY Number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY Number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop GROUP BY name HAVING avg(number_products) > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.Bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id ORDER BY bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID WHERE T1.Course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id GROUP BY T1.visitor_ID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID WHERE T1.total_spent = (SELECT max(total_spent) FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.museum_id , T2.name FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id GROUP BY T1.museum_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_ID WHERE T1.level_of_membership = \"Lv 1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_name WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_name WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'yes' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T1.player_id = T3.player_id ORDER BY T3.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T1.player_id = T3.player_id ORDER BY T3.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id JOIN players AS T3 ON T1.loser_id = T3.player_id WHERE T3.country_code = 'Australia' ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T2.player_id = T3.player_id WHERE T1.year = 2000 AND T3.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT loser_name , winner_name FROM matches ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.ranking FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.round , T1.year LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.ranking FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year , T1.match_num LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = 'left' INTERSECT SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_hand WHERE T1.hand = 'right'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\" AND T2.year = 1993", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.id , t1.name FROM ship AS t1 JOIN death AS t2 ON t1.id = t2.caused_by_ship_id GROUP BY t1.id ORDER BY sum(t2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT lost_in_battle FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES ORDER BY course_description ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id JOIN courses AS T3 ON T1.state_province_county = T3.state_province_county WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id JOIN student_enrolment AS T3 ON T3.student_id = T2.student_id JOIN degree_programs AS T4 ON T4.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE permanent_address_id IN (SELECT address_id FROM addresses WHERE state_province_county = \"North Carolina\") EXCEPT SELECT T1.last_name FROM students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT T2.cell_mobile_number FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Greenland\" AND T2.first_name = \"Timmothy\" AND T2.last_name = \"Ward\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_id WHERE T2.transcript_date = (SELECT max(transcript_date) FROM transcripts) AND T2.degree_program_id = (SELECT degree_program_id FROM Degree_Programs WHERE degree_summary_name = 'Bachelor\\'s Degree')\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 , T1.city FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = \"Master\" INTERSECT SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "{\"sql\": \"SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id JOIN Student_Enrolment_Courses AS T4 ON T4.student_enrolment_id = T2.student_enrolment_id JOIN Degree_Programs AS T5 ON T5.degree_program_id = T2.degree_program_id JOIN Courses AS T6 ON T6.course_id = T5.department_id JOIN Transcripts AS T7 ON T7.transcript_id = T4.transcript_id JOIN Departments AS T8 ON T8.department_id = T5.department_id JOIN Student_Enrolment_Courses AS T9 ON T9.student_enrolment_id = T4.student_enrolment_id JOIN Courses AS T10 ON T10.course_id = T6.course_id JOIN Transcripts AS T11 ON T11.transcript_id = T9.transcript_id JOIN Departments AS T12 ON T12.department_id = T5.department_id JOIN Student_Enrolment_Courses AS T13 ON T13.student_enrolment_id = T9.student_enrolment_id JOIN Courses AS T14 ON T14.course_id = T10.course_id JOIN Transcripts AS T15 ON T15.transcript_id = T13.transcript_id JOIN Departments AS T16 ON T16.department_id = T5.department_id JOIN Student_Enrolment_Courses AS T17 ON T17.student_enrolment_id = T9.student_enrolment_id JOIN Courses AS T18 ON T18.course_id = T10.course_id JOIN Transcripts AS T19 ON T19.transcript_id = T17.transcript_id JOIN Departments AS T20 ON T20.department_id = T5.department_id JOIN Student_Enrolment_Courses AS T21 ON T21.student_enrolment_id = T17.student_enrolment_id JOIN Courses AS T22 ON T22.course_id = T10.course_id JOIN Transcripts AS T23 ON T23.transcript_id = T21.transcript_id JOIN Departments AS T24 ON T24.department_id = T5.department_id JOIN Student_Enrolment_Courses AS T25 ON T25.student_enrolment_id = T17.student_enrolment_id JOIN Courses AS T26 ON T26.course_id = T10.course_id JOIN Transcripts AS T27 ON T27.transcript_id = T25.transcript_id JOIN Departments AS T28 ON T28.department_id = T5.department_id JOIN Student_Enrolment_Courses AS T29 ON T29.student_enrolment_id = T17.student_enrolment_id JOIN Courses AS T30 ON T30.course_id = T10.course_id JOIN Transcripts AS T31 ON T31.transcript_id = T29.transcript_id JOIN Departments AS T32 ON T32.department_id = T5.department_id JOIN Student_Enrolment_Courses AS T33 ON T33.student_enrolment_id = T17.student_enrolment_id JOIN Courses AS T34", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN students AS T3 ON T1.student_id = T3.student_id WHERE T2.country = \"Haiti\" OR T3.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id IN (SELECT address_id FROM addresses WHERE country = \" Haiti ) AND cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM TV_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content LIKE \"%Sky Radio%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM tv_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE series_name = \"Sky Radio\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.Channel = T2.Channel WHERE T2.Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT title FROM cartoon WHERE content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY id DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_Channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE HDTV = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.Content = \"Some cartoon\" AND T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"TV Series\" AND T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.channel = t2.channel WHERE t2.title = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT country FROM TV_channel EXCEPT SELECT DISTINCT directed_by FROM cartoon AS T1 JOIN cartoon AS T2 ON T1.channel = T2.channel WHERE T1.id = 18_49_Rating_Share", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Ben Jones' OR t2.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id JOIN tv_series AS t3 ON t2.id = t3.episode WHERE t1.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id JOIN tv_series AS t3 ON t2.id = t3.episode WHERE t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel WHERE id NOT IN (SELECT directed_by FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT directed_by FROM cartoon", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM tv_channel EXCEPT SELECT T1.package_option FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT Channel FROM cartoon) AND directed_by = \"Ben Jones\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT created , state , phone_number FROM VOTES WHERE contestant_number = (SELECT contestant_number FROM CONTESTANTS WHERE contestant_name = 'Tabatha Gehling')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "{\"sql\": \"SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.state = 'GA' INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independYear > 1950 ORDER BY name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Southwest';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT country) FROM city WHERE country = \"República\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Capital == T2.Distribution WHERE T2.Name == \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Capital == T2.Distribution WHERE T2.Name == \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE name = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(tp.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.countrycode WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Africa\" AND region = \"republican\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND region = 'republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE name = 'Asia' OR name = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = \"North America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE region = 'US_territory'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = 'AFG' AND isofficial = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country Code = \"AFG\" AND isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code2 WHERE t1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = T2.IsOfficial WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = 'Asia' ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = (SELECT T3.Code FROM country AS T3 ON T3.Name = 'Russian Federation')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT Language FROM countrylanguage GROUP BY Language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.countrycode = t2.countrycode WHERE t2.Language = \"English\" GROUP BY t1.name ORDER BY sum(t1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.capital = t2.countrycode WHERE t2.Language = \"English\" ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code2 = T2.code WHERE T1.name = 'Asia' ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 0 AND T1.name != 'England'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T1.name = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(T1.IsOfficial) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.indepyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(isofficial) FROM countrylanguage WHERE independyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE continent != 'Europe' AND surfacearea > (SELECT max(surfacearea) FROM country WHERE continent != 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE continent = \"Asia\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = \"Africa\" EXCEPT SELECT name FROM country WHERE population > (SELECT max(population) FROM country WHERE continent = \"Asia\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' GROUP BY name HAVING max(population) > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage EXCEPT SELECT countrycode FROM country WHERE governmentform = 'Republic' AND language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country EXCEPT SELECT CountryCode FROM countrylanguage WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = 0 AND T2.Name IN ( \"Austria\" , \"Belgium\" , \"Czech Republic\" , \"Denmark\" , \"France\" , \"Germany\" , \"Ireland\" , \"Italy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" AND T2.Code IN (SELECT T1.CountryCode FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Chinese\" AND T2.Language = \"IsOfficial\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.code WHERE T2.continent = 'Asia' AND T3.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indepyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.population , t1.name , t1.HeadOfState FROM city AS t1 JOIN country AS t2 ON t1.CountryCode = t2.Code ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population >= 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population >= 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(population) FROM city WHERE countrycode = 'NOAA' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000 - 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.Percentage FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY SUM(T2.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.Percentage FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" ORDER BY T2.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(Percentage) FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE Orchestra = \"CD\" OR Orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM Highschooler GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 111 AND T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = kyle.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.name = \"Kyle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes WHERE liked_id IN (SELECT id FROM likes WHERE liked_id = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes WHERE liked_id = (SELECT id FROM likes WHERE liked_id = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT grade FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.cell_number , T1.last_name , T1.home_phone FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN owners AS T2 ON T1.professional_id = T2.professional_id WHERE T2.state = \"Indiana\" UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.professional_id = T3.professional_id WHERE T3.email_address = (SELECT T4.email_address FROM owners AS T4 WHERE T4.zip_code = (SELECT T5.zip_code FROM owners AS T5 WHERE T5.street = \"X\")) AND sum(T2.cost_of_treatment) > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.owner_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type WHERE T2.charge_amount = (SELECT min(charge_amount) FROM charges)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type WHERE T2.charge_amount = (SELECT min(charge_amount) FROM charges)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.professional_id HAVING avg(T2.treatment_type_code) < (SELECT treatment_type_code FROM treatments GROUP BY treatment_type_code ORDER BY count(*) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city AND T1.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , count(*) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT citizenship FROM singer GROUP BY citizenship ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.name FROM song AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id WHERE T1.sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.SALES > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT T1.property_name FROM properties AS T1 JOIN other_property_features AS T2 ON T1.property_id = T2.property_id WHERE T1.property_type_code = \"apartment\" AND T1.room_count > 1 UNION SELECT T1.property_name FROM properties AS T1 JOIN other_property_features AS T2 ON T1.property_id = T2.property_id WHERE T1.property_type_code = \"house\"", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..9d8f8e3c5599709dc9bf981ed67a02d26889d540 --- /dev/null +++ b/infer/qwen/spider_realistic/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_name , T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T1.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T1.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM concert ORDER BY capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM concert ORDER BY capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE pet_age > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT min(weight) FROM Pets WHERE petage = (SELECT min(petage) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = T1.age AND T2.pet_type = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker JOIN car_names AS T3 ON T2.Model = T3.Model WHERE T3.Make = \"1970\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.Maker , t2.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.makeid WHERE t2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "{\"sql\": \"SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.fullName = (SELECT t2.fullName FROM car_makers AS t2 JOIN car_makers AS t3 ON t2.maker = t3.maker WHERE t3.fullName = (SELECT t3.fullName FROM car_makers AS t3 JOIN car_makers AS t4 ON t3.maker = t4.maker WHERE t4.fullName = (SELECT t4.fullName FROM car_makers AS t4 JOIN car_makers AS t5 ON t4.maker = t5.maker WHERE t5.fullName = (SELECT t5.fullName FROM car_makers AS t5 JOIN car_makers AS t6 ON t5.maker = t6.maker WHERE t6.fullName = (SELECT t6.fullName FROM car_makers AS t6 JOIN car_makers AS t7 ON t6.maker = t7.maker WHERE t7.fullName = (SELECT t7.fullName FROM car_makers AS t7 JOIN car_makers AS t8 ON t7.maker = t8.maker WHERE t8.fullName = (SELECT t8.fullName FROM car_makers AS t8 JOIN car_makers AS t9 ON t8.maker = t9.maker WHERE t9.fullName = (SELECT t9.fullName FROM car_makers AS t9 JOIN car_makers AS t10 ON t9.maker = t10.maker WHERE t10.fullName = (SELECT t10.fullName FROM car_makers AS t10 JOIN car_makers AS t11 ON t10.maker = t11.maker WHERE t11.fullName = (SELECT t11.fullName FROM car_makers AS t11 JOIN car_makers AS t12 ON t11.maker = t12.maker WHERE t12.fullName = (SELECT t12.fullName FROM car_makers AS t12 JOIN car_makers AS t13 ON t12.maker = t13.maker WHERE t13.fullName = (SELECT t13.fullName FROM car_makers AS t13 JOIN car_makers AS t14 ON t13.maker = t14.maker WHERE t14.fullName = (SELECT t14.fullName FROM car_makers AS t14 JOIN car_makers AS t15 ON t14.maker = t15.maker WHERE t15.fullName = (SELECT t15.fullName FROM car_makers AS t15 JOIN car_makers AS t16 ON t15.maker = t16.maker WHERE t16.fullName = (SELECT t16.fullName FROM car_makers AS t16 JOIN car_makers AS t17 ON t16.maker = t17.maker WHERE t17.fullName = (SELECT t17.fullName FROM car_makers AS t17 JOIN car_makers AS t18 ON t17.maker = t18.maker WHERE t18.fullName = (SELECT t18.fullName FROM car_makers AS t18 JOIN car_makers AS t19 ON t18.maker = t19.maker WHERE t19.fullName = (SELECT t19.fullName FROM car_makers AS t1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.full_name FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'Amcor' AND model = 'Hornet Sportabout (SW)';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T2.Id FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T2.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.countryname , T2.countryid FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid GROUP BY T2.countryid HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"France\" GROUP BY T1.CountryName HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.MPG = (SELECT max(MPG) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT make FROM car_names WHERE model = (SELECT min(mpg) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT DISTINCT make FROM car_names GROUP BY make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.Maker = \"General Motors\" OR T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.Maker = \"General Motors\" UNION SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.Maker = \"General Motors\" AND T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Volvo\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Volvo\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(DISTINCT country) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"4 CYL\" GROUP BY model ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "{\"sql\": \"SELECT DISTINCT model FROM model_list WHERE weight < 3500 AND maker != 'Ford'}", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE T2.maker = 'Ford' OR T2.maker = 'Chrysler' UNION SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE T2.maker = 'Fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country JOIN cars_data AS T3 ON T2.Id = T3.MakeId GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT CountryId , CountryName FROM countries JOIN car_makers ON countries.CountryId = car_makers.Country WHERE car_makers.Maker = \"FIAT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'ATO' OR destairport = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = \"Aberdeen\" INTERSECT SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'Aberdeen' AND T2.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Aline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Aline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'United Airlines' AND T2.DestAirport = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"United\" AND T2.DestAirport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'United Airlines' AND T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.destairport = T3.airportcode WHERE T3.airportname = 'Aberdeen' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"United\" AND T2.sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Aline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Aline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen' OR T2.airportname = 'Abilene'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DISTINCT destinationairport FROM flights UNION SELECT DISTINCT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DISTINCT DestAirport FROM flights UNION SELECT DISTINCT SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT T2.Hometown , count(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Subject = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE level_of_membership != 'LV 4'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id JOIN museum AS T3 ON T1.Museum_ID = T3.Museum_ID GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.ID , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID WHERE T1.Total_spent = (SELECT max(T1.Total_spent) FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID WHERE T1.open_year = (SELECT max(open_year) FROM museum))", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.Total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T1.level_of_membership = \"Lv 1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.rank_points FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.rank_points FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY sum(T2.rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN players AS T3 ON T2.winner_id = T3.player_id WHERE T1.tours = 'Australian Open' ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id WHERE T2.tours = \"Australian Open\" ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.loser_name , T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.year , T2.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_hand) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"WTA Championships\" AND T2.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = 'left' AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T2.caused_by_ship_id ORDER BY sum(injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T2.name , T2.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T1.result = 'Loss' AND T1.latin_commander = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE current_address_id IN (SELECT address_id FROM addresses WHERE state_province_county = 'North Carolina') EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE permanent_address_id IN (SELECT T1.line_1 , T1.line_2 , T1.line_3 , T1.state_province_county FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.state_province_county = 'North Carolina') EXCEPT SELECT T3.last_name FROM students AS T3 JOIN student_enrolment AS T4 ON T3.student_id = T4.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT T2.cell_mobile_number FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Timmothy\" AND T2.first_name = \"Timmothy\" AND T2.last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.line_1 , T1.line_2 , T1.line_3 , T1.city , T1.zip_postcode , T1.state_province_county , T1.country , T1.other_address_details FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Master' INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Masters' INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN students AS T3 ON T1.student_id = T3.student_id WHERE T2.country = 'Haiti' OR T3.cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id IN (SELECT T1.address_id FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T2.first_name = 'Haiti') OR cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE country = \"Sky\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.Channel FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.Channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE series_name = 'Sky Radio')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT original_air_date FROM TV_series WHERE series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.Episode = T2.episode WHERE T2.title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.channel FROM TV_channel AS T1 JOIN tv_series AS T2 ON T1.id = T2.channel WHERE T2.episode = 18_49_Rating_Share AND T2.weekly_rank = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_channel AS T1 JOIN tv_series AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel EXCEPT SELECT T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Ben Jones' INTERSECT SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM TV_channel WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT Channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T1.state , T2.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.state FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state JOIN CONTESTANTS AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T1.state FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state JOIN CONTESTANTS AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE indepyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE indepyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN country AS T2 ON T1.Continent = T2.Continent WHERE T2.Name = \"Carribean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Capital = T2.District WHERE T2.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Capital WHERE T2.Name = \"Kabul\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = (SELECT countrycode FROM city WHERE name = 'Aruba') GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'ARU' ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.region , T1.population FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Population , T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(t2.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND Region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND Region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT Population FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North' OR continent = 'South' OR continent = 'West' OR continent = 'East'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(GNP) , sum(Population) FROM country WHERE Continent = \"North America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.name = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND code = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND countrycode = 'AFR'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = 'China'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE continent = 'Asia' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia' GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE IsOfficial = 0 AND Language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language != \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndpYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE independyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language != \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE Code NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = \"english\") AND Region != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE Continent != \"Asia\" AND Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode = (SELECT code FROM country WHERE continent = 'Europe' EXCEPT SELECT countrycode FROM countrylanguage WHERE isofficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Asia' AND T2.code2 = (SELECT countrycode FROM countrylanguage WHERE language = 'Chinese' AND isofficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T3.isofficial = 1 AND T2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , surfacearea FROM country ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indepyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.population , T2.name , T2.headofstate FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Population) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"North America\" AND T1.SurfaceArea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population > 160000 AND population < 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT Language , Percentage FROM countrylanguage ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language , ROUND(Percent , 2) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY ROUND(Percent , 2) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Percentage) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM country WHERE language = \"Spanish\" ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\" GROUP BY T2.CountryCode ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE Orchestra = \"CD\" OR Orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM highschooler GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM FRIEND AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 101", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM FRIEND AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 589", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friends)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM Professionals JOIN Treatment_Types ON Treatment_Types.treatment_type_code = \"Capture\" JOIN treatments ON treatments.professional_id = professionals.professional_id GROUP BY professionals.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T3.owner_id = T2.owner_id WHERE T3.first_name + T3.last_name > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t1.treatment_type_description FROM treatment_types AS t1 JOIN treatments AS t2 ON t1.treatment_type_code = t2.treatment_type_code ORDER BY t2.cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code != (SELECT treatment_type_code FROM treatments GROUP BY treatment_type_code ORDER BY count(*) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT count(*) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_worth_millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..8f815ef5f61d7beeae4432a05f843cc3fb5fb36e --- /dev/null +++ b/infer/qwen/spider_realistic/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN concert AS T2 ON T1.singer_id = T2.singer_id WHERE T1.song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN concert AS T2 ON T1.singer_id = T2.singer_id WHERE T1.song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = (SELECT PetID FROM Pets WHERE PetType = \"Cat\" OR PetType = \"Dog\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" OR T3.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"Cat\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.petage = \"Cat\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.petage = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = (SELECT PetID FROM Pets WHERE petage = 10)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = (SELECT PetID FROM Pets WHERE pet_age > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = (SELECT PetID FROM Pets WHERE petage > 10)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT fname FROM student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetType = \"dog\") EXCEPT SELECT fname FROM student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetType = \"cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Students WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT Model FROM car_names WHERE Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM car_names WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T2.Make = \"1970\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year - T1.Year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.MakeId ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Accelerate = \"Carr\" ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY t2.id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"Amaterasu\" AND model = \"Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Id HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT t1.countryname , t2.id FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.countryname != \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY sum(mpg) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT make FROM car_names GROUP BY make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Weight > 3500 OR T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"Toyota\" AND T1.Model > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Volvo\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Volvo\" AND Accelerate = (SELECT min(Accelerate) FROM cars_data WHERE Make = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"4 CYL\" GROUP BY model ORDER BY max(horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT DISTINCT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"FIAT\" GROUP BY T1.CountryId HAVING COUNT(*) > 3 UNION SELECT T1.CountryId , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"FIAT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Ford\" OR T2.Maker = \"BMW\" OR T2.Maker = \"Chrysler\" OR T2.Maker = \"Toyota\" OR T2.Maker = \"Honda\" OR T2.Maker = \"Mini\" OR T2.Maker = \"Nissan\" OR T2.Maker = \"Tesla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE countryabbreviation = 'AK'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE countryabbreviation = 'AK'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = (SELECT airportcode FROM airports WHERE countryabbreviation = 'APG')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Aberdeen' AND T1.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" AND T2.AirportCode = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T1.Airline = 'United Airlines' AND T2.DestAirport = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY\" AND T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T1.airline = 'United Airlines' AND T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.SourceAirport = T2.airline WHERE T2.Airline = \"United Airlines\" AND T1.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T1.airline = 'United Airlines' AND T2.destairport = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" AND T1.Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T1.Airline = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T1.Airline = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.destairport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.destairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT airline FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T1.sourceairport = 'CVO' EXCEPT SELECT airline FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T1.sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT airline FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'CVO' EXCEPT SELECT airline FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.Airline WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT srcairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id JOIN evaluation AS T3 ON T2.employee_id = T3.employee_id ORDER BY T3.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT DISTINCT district FROM shop WHERE number_products < 3000 INTERSECT SELECT DISTINCT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT count(*) , Hometown FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(Age) FROM visitor WHERE LEVEL_OF_MEMBERSHIP <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT Museum_ID , Name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.ID , T2.Name , T2.Age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID GROUP BY T2.ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name , T2.Level_of_membership FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID GROUP BY T2.Museum_ID ORDER BY sum(T2.Total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Museum_ID , T1.Name FROM museum AS T1 JOIN visit AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T2.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.Total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T1.Level_of_membership = \"Lv 1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id WHERE T3.year = 2013 INTERSECT SELECT T1.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id WHERE T3.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'yes' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T2.player_id = T3.winner_id WHERE T3.tourney_name = \"Australian Open\" ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.loser_name , T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_hand) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"WTA Championships\" AND T2.hand = \"left-hand\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = 'left' AND T2.tourney_name = 'WTA Championships'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T2.caused_by_ship_id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'loss' AND T1.name = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%math%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE current_address_id IN (SELECT address_id FROM addresses WHERE state_province_county = 'North Carolina') EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE state_province_county = 'North Carolina' EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.line_1 , T2.line_2 , T2.line_3 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Master' INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.degree_program_id = 'Masters' INTERSECT SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.degree_program_id = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN courses AS T3 ON T2.line_1 = T3.line_1 WHERE T2.country = 'Haiti' OR T1.cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE cell_mobile_number = 09700166582 OR permanent_address_id IN (SELECT T1.permanent_address_id FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.country = \"Haiti\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.id WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.series_name FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.series_name FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t1.title FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM cartoon WHERE series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Series_Name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t2.series_name FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t1.content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT title FROM cartoon WHERE content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HDTV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.channel WHERE T1.content = 'Cartoon' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t2.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t2.series_name , t2.country FROM cartoon AS t1 JOIN TV_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Ben Jones\" INTERSECT SELECT t2.series_name , t2.country FROM cartoon AS t1 JOIN TV_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t2.series_name , t2.country FROM cartoon AS t1 JOIN TV_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Ben Jones\" INTERSECT SELECT t2.series_name , t2.country FROM cartoon AS t1 JOIN TV_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T2.Package_Option FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.Channel = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Nationality FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID GROUP BY T2.Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T2.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T3.contestant_number FROM CONTESTANTS AS T3 JOIN VOTES AS T4 ON T3.contant_number = T4.contant_number WHERE T4.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.contestant_number FROM CONTESTANTS AS T3 JOIN VOTES AS T4 ON T3.contant_number = T4.contant_number WHERE T4.contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE Region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T2.SurfaceArea) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Carribean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = 'AF' AND name = 'Anguilla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = 'Anguilla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = (SELECT countrycode FROM city WHERE name = 'Aruba')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.Population , T1.LifeExpectancy FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Population , T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND lifeexpectancy = (SELECT min(lifeexpectancy) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(gnp) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Republic\" AND Continent = \"Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND Region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT Population FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN city AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Afghanistan' AND T1.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Afghanistan' AND T1.isofficial = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY sum(percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 OR T2.Language = \"English\" UNION SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.Language = \"English\" GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.countrycode = t2.countrycode WHERE t2.Language = \"English\" GROUP BY t1.name ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code WHERE T1.continent = 'Asia' ORDER BY T1.surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.name NOT IN (SELECT T1.countrycode FROM countrylanguage AS T3 JOIN country AS T4 ON T3.countrycode = T4.code WHERE T3.Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT population FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode EXCEPT SELECT T1.population FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT t1.Language FROM countrylanguage AS t1 JOIN country AS t2 ON t1.CountryCode = t2.Code WHERE t2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT isofficial) FROM countrylanguage WHERE independyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT name FROM country WHERE population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE Code NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country EXCEPT SELECT CountryCode FROM countrylanguage WHERE Language = \"English\" INTERSECT SELECT CountryCode FROM country WHERE GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE CountryCode != 'USA' INTERSECT SELECT CountryCode FROM countrylanguage WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0) AND continent = \"Europe\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.Continent = \"Asia\" AND T3.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.population , t1.name , t1.headOfState FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code WHERE t1.surfacearea = (SELECT max(surfacearea) FROM country)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population >= 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Population) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Nothe\" AND T1.SurfaceArea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population > 160000 INTERSECT SELECT name FROM city WHERE population < 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.Population FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY SUM(T1.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.CountryCode , COUNT(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Percentage) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Spanish\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY SUM(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE Orchestra = \"CD\" OR Orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE ID = (SELECT student_id FROM likes WHERE liked_id = (SELECT student_id FROM likes GROUP BY student_id HAVING count(*) >= 2));", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM friend WHERE student_id = 96756", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , name FROM Highschooler GROUP BY name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM Highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name , grade , count(*) FROM Highschooler GROUP BY name , grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 1019 AND T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 119 AND T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Ffriend WHERE student_id = 5001;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(DISTINCT friend_id) FROM FRIEND WHERE student_id = 53266;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN student_id AS T2 ON T1.student_id = T2.student_id WHERE T2.id = 169", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN student_id AS T2 ON T1.student_id = T2.student_id WHERE T2.id = 199 AND T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT student_id FROM Friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM OWNERS AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T2.role_code , T2.first_name FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.owner_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.professional_id HAVING avg(treatment_type_code) < (SELECT treatment_type_code FROM treatments GROUP BY treatment_type_code HAVING count(*) < 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , count(*) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Country , MAX(Net_Worth_Millions) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..3900908813294c73309f2d53bb4dfff498736f9b --- /dev/null +++ b/infer/qwen/spider_realistic/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT T1.name , t1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT T1.concert_id FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN stadium AS T3 ON T3.stadium_id = T2.stadium_id WHERE T3.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"Cat\" OR T3.pet_type = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" OR T3.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID WHERE T2.PetType = \"Cat\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID WHERE T2.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_type = \"Cat\" EXCEPT SELECT major , age FROM Student WHERE sex = \"M\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT PetType , pet_age FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = \"Cat\" AND T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T1.Year FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid WHERE T2.model = (SELECT make FROM cars_data ORDER BY YEAR LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT model FROM car_names WHERE make > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.countryid GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"AMCATRON\" AND model = \"SW\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.CountryId WHERE T2.CountryName = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make JOIN countries AS T3 ON T3.id = T2.makeid WHERE T3.CountryName = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN country AS T2 ON T1.countryid = T2.id WHERE T2.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T2.CountryName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T2.CountryName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.FullName , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.Continent = \"Europe\" GROUP BY T2.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryHiah ORDER BY COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE weight > (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY weight ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT make FROM cars_data GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'USA' AND maker = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2._maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.weight > 3500 OR T1.maker = 'General Motors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = \"General Motors\" OR T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE horsepower BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Cylinders) FROM cars_data WHERE Make = \"Volvo\" AND Accelerate = (SELECT min(Accelerate) FROM cars_data WHERE Make = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE make = \"Volvo\" AND accelerate = (SELECT min(accelerate) FROM cars_data WHERE make = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM car_makers WHERE country > (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE countryid = (SELECT count(*) FROM countries WHERE", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.id = t2.make WHERE t1.cylinders = 4 GROUP BY t2.model ORDER BY t1.horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 UNION SELECT max(MPG) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T1.make = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.fullname = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM cars_data AS T1 JOIN countries AS T2 ON T1.id = T2.CountryId JOIN car_makers AS T3 ON T3.id = T1.id GROUP BY T3.id HAVING count(*) > 3 UNION SELECT T1.CountryId , T2.CountryName FROM cars_data AS T1 JOIN countries AS T2 ON T1.id = T2.CountryId JOIN car_makers AS T3 ON T3.id = T1.id WHERE T3.FullName = 'FIAT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING count(*) > 3 UNION SELECT CountryId , CountryName FROM cars_data WHERE Make = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\" AND T2.FlightNo = \"202401051234\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Aberdeen' AND T2.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.abbreviation = T2.airline WHERE T1.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.abbreviation = T2.airline WHERE T1.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T1.Abbreviation = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode JOIN airlines AS T3 ON T3.Abbreviation = T1.DestAirport WHERE T3.Airline = 'United' AND T2.city = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T1.Abbr = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T1.Abbreviation = \"United\" AND T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T1.abbr = \"United Airlines\" AND T2.destairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Aberdeen\" AND T1.airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'CVO' EXCEPT SELECT DISTINCT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.ABreviation WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.airline , T1.FlightNo FROM airlines AS T1 JOIN flights AS T2 ON T1.abbreviation = T2.destairport WHERE T1.airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.AirportCode = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights , flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline JOIN airports AS T3 ON T1.destairport = T3.airportcode)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DestAirport FROM flights OR SELECT SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM Employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT LOCATION , count(*) FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT LOCATION , count(*) FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id ORDER BY bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM shop AS t1 JOIN hiring AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher EXCEPT SELECT Name FROM teacher WHERE Hometown = 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT T2.Hometown , count(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 35 AND Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT Name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership <= \"Lv 4\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id JOIN museum AS T3 ON T1.museum_ID = T3.museum_ID GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM museum AS T1 JOIN visitor AS T2 ON T1.Museum_ID = T2.visitor_ID JOIN visit AS T3 ON T2.id = T3.visitor_ID GROUP BY T2.id ORDER BY SUM(T3.total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visitor AS T1 JOIN museum AS T2 ON T1.ID = T2.Museum_ID GROUP BY T2.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.Total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T1.level_of_membership = 'lv 1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tournamentney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE T2.tournamentney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.country_code = \"Australia\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.loser_name , T2.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.loser_id = T2.player_id ORDER BY minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.first_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'lost' AND T1.latin_commander = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port\" AND line_1 = \"Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id JOIN degree_programs AS T3 ON T3.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN student_enrolment AS T3 ON T1.student_id = T3.student_id JOIN degree_programs AS T4 ON T3.degree_program_id = T4.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_id ORDER BY T2.transcript_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 , T1.city FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.line_1 , T2.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Master' UNION SELECT T1.semester_name FROM Semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Student_Enrolment_Courses AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id JOIN courses AS T4 ON T3.course_id = T4.course_id JOIN degree_programs AS T5 ON T5.degree_program_id = T2.degree_program_id WHERE T5.degree_summary_name = 'Masters' INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Student_Enrolment_Courses AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id JOIN courses AS T4 ON T3.course_id = T4.course_id JOIN degree_programs AS T5 ON T5.degree_program_id = T2.degree_program_id JOIN students AS T6 ON T6.student_id = T2.student_id WHERE T5.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" UNION SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" AND T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE cell_mobile_number = \"09700166582\" OR permanent_address_id IN (SELECT address_id FROM addresses WHERE country = \"Haiti\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM cartoon ORDER BY Title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = (SELECT id FROM cartoon WHERE directed_by = \"Ben Jones\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN television_series AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM TV_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Country = \"Sky\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T2.Channel , T1.Series_name FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE id IN (SELECT Channel FROM cartoon WHERE title = \"The Rise of the Blue Beetle\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM Cartoon AS T1 JOIN TV_Channel AS T2 ON T1.Channel = T2.id WHERE T2.content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE content = 'Sky Radio' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Air_Date FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.channel WHERE T1.Series_Name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.Channel = T2.Channel WHERE T2.Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Series_Name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM cartoon WHERE CONTENT = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_Channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM tv_channel WHERE Hight_definition_TV = \"HDTV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T2.country FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id JOIN tv_series AS T3 ON T3.channel = T2.id WHERE T3.episode = 1 AND T1.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM tv_channel WHERE id NOT IN (SELECT Channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_channel EXCEPT SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.channel = T2.channel WHERE T2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t2.series_name , t2.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id JOIN tv_series AS t3 ON t2.channel = t3.id WHERE t1.directed_by = \"Ben Jones\" AND t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t2.series_name , t2.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = 'Ben Jones' INTERSECT SELECT t2.series_name , t2.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'en'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T2.Package_Option FROM Cartoon AS T1 JOIN TV_channel AS T2 ON T1.id = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT Channel FROM cartoon) AND directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT money_rank FROM poker_player ORDER BY people_id DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T1.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T3.contestant_number FROM votes AS T3 JOIN contestants AS T4 ON T3.contestant_number = T4.contestant_number WHERE T4.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.contestant_number FROM votes AS T3 JOIN contestants AS T4 ON T3.contestant_number = T4.contestant_number WHERE T4.contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'North American'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT country) FROM city WHERE region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T2.SurfaceArea) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Carribean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"ANGUILLA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"ANGUILLA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Capital = T2.District WHERE T2.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT district FROM city WHERE population = capital AND name = 'Kabul'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(T1.Population) , max(T2.GNP) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE region = 'Republic' AND code <= 5000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT Population FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America' OR continent = 'South America' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Africa' OR continent = 'Americas'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = \"ARUD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.Code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Afghanistan\" AND T1.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.Code = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY SUM(T2.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Continent FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.continent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t1.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM city AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = \"ASIA\" GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.Code WHERE T2.District = \"Republic\" GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT language FROM countrylanguage GROUP BY countrycode HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode JOIN country AS T3 ON T2.Language = T3.Language WHERE T3.IsOfficial = 1 AND T2.Percentage = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 0 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE independyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT country FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT name FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.Code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode EXCEPT SELECT T2.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country EXCEPT SELECT countrycode FROM countrylanguage EXCEPT SELECT countrycode FROM city WHERE capital = 'India'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 1 AND language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.CountryCode WHERE T2.Language = \"Chinese\" AND T2.IsOfficial = 1 AND T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T3.isofficial = 1 AND T2.continent = 'Asia' AND T3.language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , surfacearea FROM country ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.population , t1.name , t1.HeadOfState FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code ORDER BY t2.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Population) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"North America\" AND T2.SurfaceArea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 1600000 AND 900000 - 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY SUM(T1.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT countrycode , max(percentage) FROM countrylanguage GROUP BY countrycode", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(Percentage) FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY sum(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE Orchestra = \"CD\" OR Orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "{\"sql\": \"SELECT grade FROM highschooler WHERE ID = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID FROM friend WHERE student_id = (SELECT ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE ID = (SELECT T1.ID FROM highschooler AS T1 JOIN friend AS T2 ON T1.ID = T2.student_id WHERE T2.friend_id = (SELECT T3.friend_id FROM friend AS T3 ON T3.friend_id = T2.friend_id WHERE T3.student_id = (SELECT T4.ID FROM highschooler AS T4 ON T4.ID = T5.ID WHERE T5.grade = 'A') GROUP BY T4.ID HAVING count(*) = 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , year FROM highschooler GROUP BY year", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T1.student_id = 1009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 123456", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT cell_number , last_name , home_phone FROM Professionals WHERE state = \"IND\" UNION SELECT T1.cell_number , T1.last_name , T1.home_phone FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T3.owner_id = T2.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.treatment_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.role_code HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.charge_amount LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.treatment_type_description < (SELECT avg(treatment_type_description) FROM treatment_Types)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.age = (SELECT min(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT count(*) FROM song WHERE highest_position = \"Ms.\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_wealth_millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT T1.property_name FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code WHERE T2.property_type_code = 'house' OR T1.room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..65b390ebb9cf123393ecdc9d0117e242b2065c73 --- /dev/null +++ b/infer/qwen/spider_realistic/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT Name , Country , Age FROM singer ORDER BY Age DESC LIMIT 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT T2.name , T2.song_release_year FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.singer_id = T2.singer_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.name , T2.theme , count(*) FROM singer_in_concent T1 JOIN singer T2 ON T1.singer_id = T2.singer_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concent T1 JOIN singer T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concent as T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T1.name FROM singer AS T1 JOIN singer_in_concentment AS T2 ON T1.singer_id = T2.singer_id WHERE T2.concentment_year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.concent.YEAR = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T2.name , T2.country FROM singer AS T1 JOIN singer_in_concent as T2 ON T1.singer_id = T2.singer_id WHERE T1.song_name = 'Hey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN singer_in_concent as T2 ON T1.singer_id = T2.singer_id WHERE T2.song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T1.name , T1.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T1.name , T1.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Has_pet WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Has_pet WHERE pet_age > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT T2.weight FROM Has_pem T1 JOIN Pets T2 ON T1.petid = T2.petid WHERE T1.stuid = (SELECT min(stuid) FROM Has_pem)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT sum(weight) FROM Has_pet WHERE pet_age = (SELECT max(pet_age) FROM has_pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pem AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_pod AS T1 JOIN Student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_pod AS T1 JOIN Student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petID = T3.petID WHERE T3.pettype = 'Cat' OR T3.pettype = 'Dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.petID = \"cat\" INTERSECT SELECT T1.fname , T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.petID = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'Cat' INTERSECT SELECT T1.Fname FROM Student AS T1 JOIN Has_pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'Dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE petType = 'cat')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T2.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T2.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.petID = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = 'cat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Fname , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_pem WHERE pettype = 'dog') AND StuID NOT IN (SELECT StuID FROM Has_pem WHERE pettype = 'cat')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Fname FROM Student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID = 2 AND PetType = 'dog') EXCEPT SELECT Fname FROM Student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID = 2 AND PetType = 'cat')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY weight ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , sum(weight) FROM Has_pemus WHERE petid = (SELECT petid FROM Has_pemus ORDER BY weight LIMIT 1) GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT StuID , weight FROM Has_pet WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT StuID , weight FROM Has_pet WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.lname FROM Has_pem T1 JOIN Student T2 ON T1.stuid = T2.stuid JOIN Pets T3 ON T1.petid = T3.petid WHERE T3.pemtype = 'cat' AND T3.pemtype = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.lname FROM Has_pem T1 JOIN Student T2 ON T1.stuid = T2.stuid JOIN Pets T3 ON T3.petid = T1.petid WHERE T3.pettype = 'cat' AND T3.pem_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT maker , COUNT(*) , fullname FROM car_makers GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FFullName , count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT maker FROM car_makers WHERE country = 'United States' AND YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT maker FROM car_makers WHERE country = 'United States' AND YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT maker , MIN(year) FROM cars_data WHERE id = (SELECT id FROM cars_data ORDER BY year ASC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT maker , YEAR FROM cars_data ORDER BY YEAR ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T3.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_makers AS T3 ON T2.Id = T3.Id WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE YEAR > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country_name FROM car_makers GROUP BY country_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , t1.FFullName FROM car_makers AS t1 JOIN car_names AS t2 ON t1.Id = t2.Model JOIN cars_data AS t3 ON t2.MakeId = t3.Id GROUP BY t1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FULL_NAME FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT Accelerate FROM cars_data WHERE Country = 'Amc' AND Maker = 'Amc Hornet'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN country AS T2 ON T1.country_id = T2.country_id WHERE country_name = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN country AS T2 ON T1.country_id = T2.country_id JOIN continents AS T3 ON T2 Continent = T3.Continent WHERE T2.CountryName = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN country AS T2 ON T1.country_id = T2.country_id WHERE country_name = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MGP) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT T1.MGPA FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_names AS T3 ON T3.Model = T2.Model WHERE T3.Make = \"1974\" GROUP BY T1.MGPA ORDER BY T1.MGPA ASC LIMIT 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT maker , country FROM car_makers GROUP BY country HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T1.CountryName HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid WHERE countryname = 'Europe' GROUP BY countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT countryname FROM countries WHERE countryname LIKE \"%Europe%\" GROUP BY countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_makers JOIN car_names ON car_names.MakeId = car_makers.Id JOIN cars_data ON cars_data.Id = car_names.Id GROUP BY model ORDER BY sum(accelerate) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_makers AS T3 ON T3.Id = T2.MakeId JOIN countries AS T4 ON T4.CountryId = T3.CountryId WHERE T4.CountryName = 'United States' GROUP BY T2.Model ORDER BY avg(T1.MGPH) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Country = \"VOLLE\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE maker = \"VOLVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId GROUP BY T2.Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN countries AS T3 ON T1.countryid = T3.countryid WHERE countryname = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN countries AS T3 ON T1.countryid = T3.countryid WHERE countryname = \"American\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , fullname FROM car_makers WHERE country_id = (SELECT country_id FROM car_makers GROUP BY country_id HAVING count(*) > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , COUNT(*) FROM car_makers GROUP BY maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE maker = \"General Motors\" OR weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE countryid = 2 AND mpg > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE WEIGHT BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE WEIGHT BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT accelerate , COUNT(*) FROM cars_data WHERE cylinder_count = (SELECT min(cylinders) FROM cars_data WHERE maker = \"volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT count(*) , MIN(acceleration) FROM cars_data WHERE id = (SELECT id FROM cars_data WHERE maker = \"volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers WHERE countryId NOT IN (SELECT countryId FROM countries)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker != \"Ford\" AND maker != \"Ford\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model , T2.Horsepower FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.MakeId WHERE T1.Cylinders = 4 GROUP BY T1.Model ORDER BY COUNT(*) DESC LIMIT 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MGPL) , id FROM cars_data WHERE Cylinders = 8 OR id < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE weight < 3500 EXCEPT SELECT maker FROM car_makers WHERE maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE weight < 3500 AND maker != \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT countryid , countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid GROUP BY T1.countryid HAVING count(*) > 3 OR T2.FNAME = 'fiest'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT countryid , countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid GROUP BY T1.countryid HAVING count(*) > 3 OR T2.FFullName = 'Fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname LIKE '%Anthony%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT T2.airportcode , T2.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE airline = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE Country = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberona\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'ATA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'ATA' AND flightno = 'ATOP'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"Aberon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"Aberport Airports Group\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Aberport'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'Aberport' INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Aberport\" AND destairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'JETBL Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'United Airlines' AND FlightNo = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.airline = 'United Airlines' AND T2.city = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'United Airlines' AND FlightNo = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"United Airlines\" AND FlightNo = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.airline WHERE T3.airline = 'United Airlines' AND T2.airportname = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.airline = 'United Airlines' AND T2.city = 'Aberona'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.sourceairport = 'APG' INTERSECT SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.sourceairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.sourceairport = 'APG' INTERSECT SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.sourceairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT airline FROM flights WHERE airline = \"CVO\" EXCEPT SELECT airline FROM airlines WHERE airline = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT airline FROM flights WHERE FlightNo = 'CVO' EXCEPT SELECT airline FROM airlines WHERE AirportCode = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE AirportCode = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Abilene' OR destinationairport = 'Aberona'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports WHERE airportname = 'Aberport' OR airportname = 'Abilene'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DISTINCT DostAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports EXCEPT SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee GROUP BY city HAVING min(age) > 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop GROUP BY manager_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop GROUP BY district ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.Bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.Bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM hiring GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT name FROM teacher ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID = 32 OR Teacher_ID = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT T1.hometown FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.teacher_id = T2.teacher_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT T1.hometown , count(*) FROM teacher AS T1 GROUP BY T1.hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT name FROM teacher WHERE name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course_Name = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT T2.Name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.ID WHERE T2.Level_of_membership > 4 ORDER BY T2.Level_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(Age) FROM visitor WHERE Level_of_membership < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T1.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id WHERE T1.total_spent = (SELECT max(total_spent) FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM visit GROUP BY museum_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_spex) FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id WHERE T2.level_of_membership = \"lv\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tournament_name FROM matches GROUP BY tournament_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.wider_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR BETWEEN 2013 AND 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR BETWEEN 2013 AND 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.writer_age = 2000 AND T2.writer_entry = 2000 AND T2.writer_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY player_id ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY player_id ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T2.loser_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T1.rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" GROUP BY T1.name ORDER BY sum(T2.rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T2.name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.name ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY match_num DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.name , T1.rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.round LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.name , T1.rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T2.match_num LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT winner_id) FROM matches WHERE tourney_name = \"WTA Championships\" AND hand = \"Left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T1.hand = \"Left\" AND T2.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE id = (SELECT id FROM ship WHERE result = 'Yes' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T2.d死了 > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T2.name , T1.date FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.lost_in_bATTLE WHERE T2.name = \"Lettice\" AND T2.name = \"HMS Atalanta\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander = \"null\" AND name NOT IN (SELECT name FROM ship WHERE lost_in_battle = \"English Channel\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT department_description FROM DEPT_DESCRIPTION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSE WHERE degree_program_id = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'North Carolina' EXCEPT SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permient_address_id = T2.address_id WHERE T2.state_province_county = 'New York'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id JOIN departments AS T3 ON T3.department_id = T1.department_id WHERE T1.state_province_county = 'North Carolina' EXCEPT SELECT T2.last_name FROM students AS T1 JOIN students AS T2 ON T1.current_address_id = T2.current_address_id JOIN degree_programs AS T4 ON T4.degree_program_id = T2.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T2.degree_program_id = degree_program_id AND T2.semester_id = 1 ORDER BY T2.student_id ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id WHERE T1.semester_id = (SELECT max(semester_id) FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.city FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanant_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM student_enrolment AS T1 JOIN semesters AS T2 ON T1.semester_id = T2.semester_id WHERE T1.degree_program_id = 'Master' INTERSECT SELECT T2.semester_name FROM student_enrolment AS T1 JOIN semesters AS T2 ON T1.semester_id = T2.semester_id WHERE T1.degree_program_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_id FROM student_enrolment AS T1 JOIN semesters AS T2 ON T1.semester_id = T2.semester_id WHERE T1.degree_program_id = 'Master's' INTERSECT SELECT T2.semester_id FROM student_enrolment AS T1 JOIN semesters AS T2 ON T1.semester_id = T2.semester_id WHERE T1.degree_program_id = 'Bachelers'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id = 'Haiti' OR cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id = 1 OR cell_phone_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM cartoon ORDER BY Title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT Directed_by FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.id = T2.id WHERE T1.title = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.id = T2.id WHERE T2.Directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.id = T2.id WHERE T2.Directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT Title , Directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT T2.Title , T1.Directed_by FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.id = T2.id ORDER BY T2.original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vieti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Channel = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Country = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE Country = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_series WHERE id = (SELECT id FROM TV_series WHERE title = \"The Rise of the Blue Beetle\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.title FROM TV_channel AS T1 JOIN cartools AS T2 ON T1.id = T2.channel WHERE T1.country = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM TV_series WHERE Title = \"Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE series_name = \"Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Series_name = \"Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_series WHERE channel = (SELECT id FROM TV_channel WHERE content = \"Love of a Lifetime\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_series WHERE series_name = \"Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.country = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT count(*) , directed_by FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE pixel_aspect_ratio_PAR = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HDTV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel JOIN tv_series AS T3 ON T2.id = T3.id WHERE T3.Series_name = \"Todd Casey\" AND T2.Content = \"Written_by\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.direction = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel WHERE content != \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_channel WHERE Country != \"United States\" AND id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Todd Casey\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT series_name , country FROM TV_channel WHERE Content = \"Ben Jones and Michael Chang directed\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT series_name , Country FROM TV_channel WHERE Content = \"Ben Jones\" INTERSECT SELECT series_name , Country FROM cartoon WHERE Content = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel WHERE Country = \"United States\" UNION SELECT id FROM TV_channel WHERE Country = \"China\" AND count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM votes WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT created , state , phone_number FROM votes WHERE contestant_number = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT state FROM votes WHERE contestant_number = (SELECT contestant_number FROM votes WHERE candidate_number = 'Tabatha Gehling) INTERSECT SELECT state FROM votes WHERE contestant_number = (SELECT contestant_number FROM votes WHERE candidate_number = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE indeleightyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE indeleightyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surface_area) FROM country WHERE continent = 'Carribean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE countrycode = 'Anguila'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE countrycode = 'Anguila'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT district FROM city WHERE name = 'Kabby'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT district FROM city WHERE name = 'Kabby'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'Aruba' ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , le expectancy FROM country WHERE countrycode = 'BR';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , 500 FROM country WHERE countrycode = 'BR';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT countrycode , population FROM country WHERE continent = \"Anguila\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT countrycode , population FROM country WHERE continent = 'Anglenext' AND region = 'Anglenext'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND row_count = 1 AND row_count = (SELECT min(row_count) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND (SELECT min(lifeexpectancy) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(population) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode WHERE countrycode = 'Africa' AND countrycode = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(life expectancy) FROM country WHERE continent = 'Africa' AND countrycode = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Continent = 'Asia' OR T1.Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM country WHERE countrycode = 'GEL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(population) , sum(population) FROM country WHERE countrycode = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(population) , sum(population) FROM country WHERE countrycode = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT type) FROM countrylanguage WHERE countrycode = \"Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE countrycode = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(percent) FROM countrylanguage WHERE countrycode = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = 'Afghanistan'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Afghanistan\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY sum(percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT countryname FROM countrylanguage ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT continent FROM countrylanguage GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT continent FROM countryGROUP BY continent ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"English\" INTERSECT SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"English\" INTERSECT SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.indpyear = 'English' INTERSECT SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.indpyear = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM country WHERE countrycode = 'France' INTERSECT SELECT name FROM country WHERE countrycode = 'England'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT continent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode WHERE T1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT continent FROM country WHERE name = 'Chinese' GROUP BY continent HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT district FROM city JOIN countrylanguage ON city.countrycode = countrycode WHERE language = \"English\" OR language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT district FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode JOIN country AS T3 ON T1.district = T3.district WHERE T2.language = \"Dutch\" OR T2.language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"English\" OR language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'Asia' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Continent = 'Asia' GROUP BY T2.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE percentage = (SELECT percentage FROM countrylanguage WHERE language = 'United States' GROUP BY language HAVING count(*) = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode NOT IN (SELECT countrycode FROM country WHERE countrycode != \"United States\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT name FROM city WHERE population = (SELECT max(population) FROM city) ORDER BY name LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT name FROM city WHERE countrycode = \"United States\" AND language = \"English\" ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , avg(lifeexpectancy) FROM country WHERE continent = 'Asia' GROUP BY countrycode ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(live expectancy) FROM countrylanguage WHERE language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(live expectancy) FROM countrylanguage WHERE language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = 'English')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM countrylanguage WHERE official_language = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Name = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE percentage = 1 AND countrycode IN (SELECT countrycode FROM countrylanguage WHERE indepyear < 1930))", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode = \"United States\" AND indeyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT countrycode FROM country WHERE surfacat > (SELECT max(surfacat) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT countrycode FROM country WHERE continent = \"Europe\" EXCEPT SELECT countrycode FROM country WHERE countrycode IN (SELECT countrycode FROM country WHERE continent = \"Europe\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT countrycode FROM country WHERE continent = 'Africa' AND population < (SELECT min(population) FROM country WHERE region = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT countrycode FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE region = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT countrycode FROM country WHERE continent = 'Asia' INTERSECT SELECT countrycode FROM country WHERE continent = 'Africa' GROUP BY countrycode ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'Asia' AND population > (SELECT max(population) FROM country WHERE countrycode = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE name != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE name != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE name != \"English\" GROUP BY countrycode", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE name != \"United States\" AND name != \"Republic\" AND countrycode != \"United States\" AND countrycode != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE region != \"Republic\" AND language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode = \"Europe\" EXCEPT SELECT name FROM city WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.indpyear = '2000' AND T2.indfname = 'Chinese' AND T2.region = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT name FROM city AS T1 JOIN country AS T2 ON T1.id = T2.countrycode JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE t2.region = 'Asia' AND t3.indelfname = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independence_year , surfacearea FROM country ORDER BY population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independence_year , surface_area FROM country ORDER BY population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT population , name , leader FROM country WHERE continent = \"Asia\" ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , T1.district FROM city AS T1 JOIN city AS T2 ON T1.district = T2.district WHERE T1.population > (SELECT avg(population) FROM city) GROUP BY T1.district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city GROUP BY district HAVING sum(population) > (SELECT avg(population) FROM city)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = \"Europe\" AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(population) FROM country WHERE continent = 'North America' AND countrycode = 'USA' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population > 160000 AND population < 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population > 160000 AND population < 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.language , T2.countrycode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode GROUP BY T2.countrycode ORDER BY sum(percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT countrycode , language FROM countrylanguage GROUP BY countrycode ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(percentage) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE percentage = (SELECT percentage FROM countrylanguage WHERE language = \"Spanish\") GROUP BY countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Orchestra FROM orchestra GROUP BY Orchestra ORDER BY YEAR_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra AS T1 JOIN orchestra AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.Major_Record_Format = \"CD\" OR T1.Major_Record_Format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = \"Kyle\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = \"Kyle\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT student_id FROM friends WHERE friend_id = 1 AND student_id = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT student_id FROM friends WHERE student_id = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM Highschooler WHERE grade = 'Highschool' GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM Highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT date FROM highschooler WHERE grade = \"Highschooler\" GROUP BY date ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T1.student_id = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T1.student_id = 1 AND T1.friend_id = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend WHERE student_id = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM friend WHERE student_id = 1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes WHERE student_id = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T2.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.friend_id GROUP BY T2.grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.ID = T2.student_id GROUP BY T1.grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id EXCEPT SELECT min(grade) FROM highschooler WHERE friend_id IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT student_id FROM friends)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_phone FROM professionals WHERE state = 'Indiana' OR SELECT professional_id FROM treatments GROUP BY professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T2.professional_id , T2.last_name , T2.cell_phone FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T1.dog_id = T3.dog_id WHERE T3.state = \"Indiana\" OR T1.treatment_type_code = \"2\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.weight = (SELECT max(weight) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.weight = (SELECT max(weight) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id GROUP BY T1.role_code HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T2.role_code , T1.first_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T3.dog_id = T2.dog_id GROUP BY T1.owner_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM Treatment_Types ORDER BY cost_of_treatment ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM Treatment_Types ORDER BY cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.breed_code = \"Labrador retrievable\" ORDER BY T2.weight DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.date_of_birth = '10/10/2012' GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id WHERE T2.treatment_type_code = (SELECT treatment_type_code FROM Treatments WHERE cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE average_expensive_in_average_expensive_in_average_of_treatment_1_2_3_4_5_6_7_8_9_10_11_12_13_14_15_16_17_18_19_20_21_22_23_24_25_26_27_28_29_30)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM PROFESSIONALS WHERE state = \"Hawaii\" OR last_name = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM PROFESSIONS WHERE first_name = \"Hawaii\" OR last_name = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 'no'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizens != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Birth_Year = 1948 OR T2.Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , count(*) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT citizenship FROM singer GROUP BY citizenship ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT citizenship FROM singer GROUP BY citizenship ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_worth_millions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_worth_millions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sale_Year = 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" OR property_type_code = \"House\" AND room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..2d834fdbc1881538b4ed2448f40b1c82da097cff --- /dev/null +++ b/infer/qwen/spider_realistic/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.name , t2.capacity FROM concert AS t1 JOIN stadium AS t2 ON t1.stadium_id = t2.stadium_id WHERE t1.year >= 2014 GROUP BY t1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.average > (SELECT max(avg) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T2.pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_age > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT PetID , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T3.PetID = T1.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT t1.lname FROM student AS t1 JOIN has_pet AS t2 ON t1.stuid = t2.stuid JOIN pets AS t3 ON t2.petid = t3.petid WHERE t3.pettype = \"Cat\" AND t3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t2.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.modelid WHERE t2.year = (SELECT min(year) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t2.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.model WHERE t2.year = (SELECT min(year) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.MPG > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid GROUP BY t1.countryname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'AmCor' AND model = 'Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.id WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(DISTINCT t1.fullname) FROM car_makers AS t1 JOIN model_list AS t2 ON t1.id = t2.maker WHERE t1.country = 'usa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" GROUP BY T2.Country HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryID GROUP BY T1.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId ORDER BY T1.MPG * T2.Cylinders DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY weight ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN car_names AS t2 ON t1.id = t2.make WHERE t1.maker = (SELECT t3.maker FROM car_makers AS t3 GROUP BY t3.maker ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" UNION SELECT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" UNION SELECT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN cars_data AS T3 ON T3.id = T2.model WHERE T1.FullName = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(cylinders) FROM cars_data WHERE accelerate = (SELECT min(accelerate) FROM cars_data) AND make = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE make = \"Volvo\" AND accelerate = (SELECT min(accelerate) FROM cars_data WHERE make = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers GROUP BY maker HAVING count(DISTINCT maker) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.weight < 3500 EXCEPT SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Ford\" GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_names AS T2 ON T1.CountryId = T2.Model WHERE T2.Model = \"Fiat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Model = ' Fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Abbreviation = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T2.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T2.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.Abbreviation = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T1.sourceairport = 'Aberdeen' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Aberdeen' AND T1.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.UID WHERE T2.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.ABBrviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.UILANGUAGE = T2.SourceAirport WHERE T1.Airline = 'United Airlines' AND T2.DestAirport = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T3.uid = T1.airline WHERE T3.AnnualFlights = 'United' AND T2.country = 'ASy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abnovation = \"United\" AND T1.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abnovation = \"United\" AND T1.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.city = 'Aberdeen' AND T1.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.country = 'United' AND T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT airline FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T1.destairport = 'CVO' EXCEPT SELECT DISTINCT airline FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T1.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.DestAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.Underline() WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\" OR T1.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\" OR T1.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights) AND airportcode NOT IN (SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT LOCATION , count(*) FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT Name FROM shop WHERE Shop_ID NOT IN (SELECT Shop_ID FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT T2.Hometown , count(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID WHERE T1.Course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID WHERE T1.Course() = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name , T2.Level_of_membership FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY sum(T1.Total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID GROUP BY T2.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum EXCEPT SELECT T2.name FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT T2.total_spent FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = \"Lv 1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'yes' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.match_num = T3.match_num WHERE T3.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.match_num = T3.match_num WHERE T3.tourney_name = 'Australian Open' ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT loser_name , winner_name FROM matches ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age , winner_rank_points LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age , winner_rank LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T2.loser_hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"Left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'loss' AND T1.latin_commander = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE permanent_address_id IN (SELECT permanent_address_id FROM addresses WHERE state_province_county = 'North Carolina') AND student_id NOT IN (SELECT student_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT T2.cell_mobile_number FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Timmothy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.degree_program_id JOIN Semesters AS T3 ON T3.semester_id = T2.semester_id JOIN Courses AS T4 ON T4.course_id = T2.course_id WHERE T2.degree_summary_name = 'Graduate' ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_id , T1.section_name FROM Student_Enrolment AS T1 JOIN Semesters AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.degree_program_id = 'Master' INTERSECT SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.degree_program_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.degree_program_id = 'Masters' INTERSECT SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.degree_program_id = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id = (SELECT permanent_address_id FROM addresses WHERE country = \"Haiti\") UNION SELECT first_name FROM students WHERE cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id = (SELECT permanent_address_id FROM students WHERE cell_mobile_number = \"09700166582\") UNION SELECT first_name FROM students WHERE cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = 'Joseph Kuhr'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM tv_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Country = \"Sky\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM tv_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE Content = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE content = 'Sky Radio')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Series_Name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Episode FROM TV_series WHERE Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_Channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = 'HD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel JOIN TV_series AS T3 ON T3.channel = T2.channel WHERE T2.directed_by = (SELECT T4.id FROM TV_channel AS T4 JOIN cartoon AS T5 ON T4.id = T5.channel WHERE T5.written_by = 'Todd Casey')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_channel EXCEPT SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT T1.country FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.content = \"Cartoon\" AND T2.write_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN Cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Ben Jones' INTERSECT SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN Cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id JOIN tv_series AS t3 ON t2.channel = t3.id WHERE t3.id = (SELECT t2.id FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id GROUP BY t1.channel HAVING sum(t1.directed_by) = 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM tv_channel WHERE country = \"Australia\" OR country = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT channel FROM cartoon", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel WHERE id NOT IN ( SELECT channel FROM cartoon ) AND directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_Channel EXCEPT SELECT T1.Package_Option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon) AND directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Final_Table_Made DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Final_Table_Made DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM VOTES WHERE state = \"CA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'CA' OR state = 'NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT created , state , phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.state = 'GA' INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = \"Tabatha Gehling\" INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = \"Kelly Clauss\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independeyyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT region) FROM country WHERE region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t2.SurfaceArea) FROM country AS t1 JOIN city AS t2 ON t1.Code = t2.CountryCode WHERE t1.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = 'ANGUILLA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Capital WHERE T2.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Capital WHERE T2.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.CountryName = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT t1.region , t1.population FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t2.name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) , t1.name FROM country AS t1 JOIN city AS t2 ON t1.Code = t2.CountryCode WHERE t1.Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(t1.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(GNP) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Africa\" AND region = \"republicate\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North' OR continent = 'South' OR continent = 'East' OR continent = 'West'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(t1.percentage) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode = (SELECT name FROM city WHERE countrycode = 'Aruba' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country.code = 'AF' AND isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = \"y\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY sum(T1.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY sum(T2.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT continent) FROM countrylanguage WHERE language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T2.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = \"North Atlantic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT L1.Language FROM countrylanguage AS L1 JOIN country AS L2 ON L1.CountryCode = L2.Code WHERE L2.Region = \"Asia\" GROUP BY L1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.CountryCode WHERE T2.Language = \"English\" GROUP BY T2.CountryCode ORDER BY sum(T2.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.countrycode = t2.CountryCode WHERE t2.Language = \"English\" GROUP BY t2.CountryCode ORDER BY t1.Population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE code NOT IN ( SELECT countrycode FROM countrylanguage WHERE isofficial = 0 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.IsOfficial = 1 AND T2.Language = T1.Language AND T1.Code = T2.CountryCode AND T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode IN (SELECT code FROM country WHERE independyear < 1930)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(IsOfficial) FROM countrylanguage WHERE CountryCode -> (SELECT countrycode FROM country WHERE independyyear < 1930)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE continent != 'Europe by land' AND surfacearea > (SELECT max(surfacearea) FROM country AS T1 JOIN country AS T2 ON T1.SurfaceArea = T2.SurfaceArea WHERE T1.Continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Asia') AND continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' WHERE population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country EXCEPT SELECT CountryCode FROM countrylanguage WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE isofficial = 1 AND language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country WHERE region != 'Asia' AND countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 1 AND language = 'English')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 0 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.CountryCode WHERE T2.Language = \"Chinese\" AND T2.IsOfficial = \"Y\" AND T1.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , surfacearea FROM country ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.population , t1.name , t1.HeadOfState FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.SurfaceArea > 30000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000 - 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T2.Language , T1.Percent , T1.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY T1.Percent DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T2.CountryCode , T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(t1.percentage) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.CountryCode = t2.Code WHERE t1.Language = \"Spanish\" ORDER BY sum(t1.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE Orchestra = \"CD\" OR Orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM highschooler GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 21001 AND T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 1019", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend WHERE student_id = (SELECT id FROM highschooler WHERE name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = (SELECT T1.student_id FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T2.name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes WHERE student_id IN (SELECT student_id FROM likes WHERE liked_id = $1) AND liked_id = $2 AND liked_id = $3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes WHERE student_id IN (SELECT student_id FROM likes WHERE liked_id = \"Kyle\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friends)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friends)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.cell_number , T1.last_name , T1.home_phone FROM owners AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"IND\" OR count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id AND T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.charge_amount LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type_code ORDER BY T2.charge_amount LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"expansive\" GROUP BY T2.professional_id HAVING avg(T2.treatment_type_code) < \"less expansive\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT COUNT(*) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_worth_millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT DISTINCT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..095db6405878471a2968083687edd6d7e4c62d00 --- /dev/null +++ b/infer/qwen/spider_realistic/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer ORDER BY Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.Year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.Year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE pet_age > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT max(weight) FROM Pets WHERE pettype = \"dog\" AND pet_age = (SELECT min(pet_age) FROM Pets WHERE pettype = \"dog\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet AS T1 JOIN student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F' AND T1.pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet AS T1 JOIN student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.pettype = \"Cat\" OR T2.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"Cat\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Students EXCEPT SELECT T1.major , T1.age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'dog' EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'cat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"dog\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.Lname FROM Students AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker JOIN car_names AS T3 ON T2.Model = T3.Model WHERE T3.MakeId IN (SELECT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = 1970)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.MakeId IN (SELECT Id FROM cars_data WHERE YEAR > 1980)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"Amaterasu\" AND model = \"Hornet Sportabout (Sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker != \"null\" GROUP BY T1.CountryName HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T1.CountryName HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150 GROUP BY Id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Europe\" GROUP BY T1.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId ORDER BY T1.MPG * T2.Model ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT make FROM cars_data GROUP BY make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.MakeId = T2.MakeId WHERE T2.Weight > 3500 AND T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.Weight > 3500 UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.Weight < 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(Cylinders) FROM cars_data WHERE Make = \"Volvo\" AND Accelerate = (SELECT min(Accelerate) FROM cars_data WHERE Make = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Volvo\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 GROUP BY model ORDER BY max(horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 UNION SELECT max(mpg) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 AND maker != 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.id = T2.id WHERE T1.maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE T2.fullname = 'fiat' GROUP BY T1.id HAVING count(*) > 3 UNION SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Ford\" GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"BMW\" GROUP BY T1.CountryId HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airline FROM airlines WHERE abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE countryabbreviation = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE countryabbreviation = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN flights AS T3 ON T1.destairport = T3.sourceairport WHERE T2.city = 'Aberdeen' AND T3.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'Aberdeen' AND T2.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'United Airlines' AND T2.DestAirport = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode JOIN airlines AS T3 ON T1.Airline = T3.UID WHERE T3.ABbr = \"United\" AND T2.City = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = 'United Airlines' AND T1.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.Abbreviation = \"U. Airlines\" AND T2.AirportCode = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode JOIN airlines AS T3 ON T1.Airline = T3.UID WHERE T3.Airline = 'United' AND T2.AirportName = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.ABbrv = \"United\" AND T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.airline WHERE T1.Above = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.airline WHERE T1.Above = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceairport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.CountryAbbrev = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceairport = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT sourceairport FROM flights UNION SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT sourceairport FROM flights UNION SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT LOCATION , count(*) FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT T2.Hometown , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID WHERE T1.Grade = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership != \"LV 4\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.ID , T2.Name , T2.Age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID JOIN museum AS T3 ON T1.Museum_ID = T3.Museum_ID GROUP BY T2.ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id WHERE T1.total_spent = (SELECT max(total_spent) FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T2.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = 'Lv 1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016 AND T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016 AND T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players WHERE birth_date = (SELECT max(birth_date) FROM players)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players WHERE birth_date = (SELECT max(birth_date) FROM players)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" GROUP BY T1.winner_name ORDER BY sum(T1.ranking_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id ORDER BY minutes DESC LIMIT 1 UNION SELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"right\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T2.caused_by_ship_id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'lost' AND T1.latin_commander = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT T1.id FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.id WHERE T1.lost_in_battle = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%math%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE current_address_id IN (SELECT address_id FROM addresses WHERE state_province_county = 'North Carolina') EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE permanent_address_id IN (SELECT address_id FROM addresses WHERE state_province_county = \"North Carolina\") EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT T2.cell_mobile_number FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.perminent_address_id WHERE T1.city = \"Timmothy\" AND T2.last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT max(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_enrolment_id JOIN Student_Enrolment_Courses AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id JOIN Courses AS T4 ON T3.course_id = T4.course_id JOIN Degree_Programs AS T5 ON T4.degree_program_id = T5.degree_program_id WHERE T5.degree_summary_name = 'Graduate' ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.section_name FROM Students AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.line_1 , T2.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Master' INTERSECT SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.last_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT semester_id FROM student_enrolment WHERE degree_program_id = 'Masters' INTERSECT SELECT semester_id FROM student_enrolment WHERE degree_program_id = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN permanent_address_id AS T2 ON T1.permanent_address_id = T2.PERMANENT_ADDRESS_ID JOIN addresses AS T3 ON T2.address_id = T3.address_id WHERE T3.country = \"Haiti\" UNION SELECT T1.first_name FROM students AS T1 JOIN current_address_id AS T2 ON T1.current_address_id = T2.address_id JOIN addresses AS T3 ON T2.address_id = T3.address_id WHERE T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE cell_mobile_number = \"09700166582\" OR permanent_address_id IN (SELECT permanent_address_id FROM addresses WHERE country = \"Haiti\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE country = \"Sky\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T2.channel FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.series_name FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t2.title FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t1.Country = \"UK\" AND t1.Language = \"English\" AND t1.Series_Name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Air_Date FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.id WHERE T1.Series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Air_Date FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.id WHERE T1.Series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank FROM TV_series AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t2.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN tv_channel AS T2 ON T1.id = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE HDTV = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel JOIN tv_series AS T3 ON T1.channel = T3.id WHERE T3.Episode = 1 AND T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel EXCEPT SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.channel = t2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel WHERE country NOT IN (SELECT T1.channel FROM cartoon AS T1 JOIN cartoon AS T2 ON T1.channel = T2.channel WHERE T1.title = 'Todd Casey' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT pixel_aspect_ratio_PAR , country FROM TV_channel WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T1.package_option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T1.Package_Option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Money_Rank , Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM People WHERE Nationality != 'Russian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM votes WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'CA' OR state = 'NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T2.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.constituent_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T1.state = 'CA' AND T2.contestant_number IN (SELECT T1.contestant_number FROM voters AS T1 JOIN contestants AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T1.contestant_number FROM voters AS T1 JOIN contestants AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T2.SurfaceArea) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Carribean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T2.Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage WHERE CountryCode = \"ARU\" GROUP BY Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Code = \"BR\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT region , population FROM country WHERE name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T2.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(population) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT gnp , count(*) FROM country WHERE continent = 'Asia' GROUP BY gnp ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' UNION SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America' UNION SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'South America' UNION SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'South America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND code = \"AF\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND countrycode = \"AF\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(*) FROM country WHERE language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT region FROM countrylanguage WHERE language = \"English\" OR language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.Country FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = '1' AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" GROUP BY T1.Name ORDER BY SUM(T1.Population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" GROUP BY T1.name ORDER BY sum(T1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.name NOT IN (SELECT T1.countrycode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(T1.IsOfficial) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT max(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT CountryCode FROM country WHERE SurfaceArea > (SELECT max(SurfaceArea) FROM country WHERE Continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Asia') AND continent = 'African'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND Population < (SELECT min(Population) FROM country WHERE Continent = \"Asia\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language != \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code FROM country WHERE Code NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = \"English\") AND GovernmentForm != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" EXCEPT SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Chinese\" AND T2.IsOfficial = \"1\" AND T1.CountryCode = \"ASIA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.id = T2.countrycode WHERE T2.IsOfficial = \"1\" AND T1.countrycode = T3.code WHERE T3.continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indeptimeyear , surfacearea FROM country ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT population , name , headofstate FROM country ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = \"Europe\" AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = \"Europe\" AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Population) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Noth\" AND T1.SurfaceArea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000 - 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT Name FROM city WHERE Population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.CountryCode , ROUND(avg(T1.Percentage) , 2) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T2.CountryCode ORDER BY avg(T1.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language , count(*) , T2.IsOfficial , T2.Percentage FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY sum(T2.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Percentage) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Spanish\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM country WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY SUM(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE Orchestra = \"CD\" OR Orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM highschooler GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 21554", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 25918", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 1463291", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 599428381", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"IND\" UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\" UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.treatment_id , T2.role_code , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.role_code HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.owner_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.treatment_type_description FROM treatments AS t1 JOIN treatment_types AS t2 ON t1.treatment_type_code = t2.treatment_type_code ORDER BY t1.cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = 'Expansive' GROUP BY T2.professional_id HAVING avg(T2.treatment_type_code) < 'Expansive'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT Name FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(networth millions) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..0dfef7b2bb98b60e158a7e225dfc188c25daf3eb --- /dev/null +++ b/infer/qwen/spider_realistic/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer ORDER BY Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer ORDER BY Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium EXCEPT SELECT T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.Year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.pettype = \"dog\" EXCEPT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.StuID = T2.StuID JOIN pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.Year FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Maker = (SELECT T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model ORDER BY T2.Year LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t3.countryname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.countryid JOIN car_makers AS t3 ON t1.id = t3.id GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.country = (SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country GROUP BY t2.country ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"Amac Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryName = T2.Country WHERE T1.CountryName = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE YEAR = 1974 AND Cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Cars\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'Car'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY weight ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT T1.Make FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model JOIN cars_data AS T3 ON T2.Model = T3.Id ORDER BY T3.MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE model = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT DISTINCT make FROM car_names GROUP BY make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.maker = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T2.Id , T2.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T2.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.Make = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id WHERE T2.FullName = 'General Motors' OR T1.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers WHERE maker = \"Ford\" OR maker = \"Chevrolet\" OR maker = \"BMW\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 4 GROUP BY T2.Model ORDER BY max(T1.Horsepower)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'Ford' GROUP BY T1.CountryId HAVING COUNT(*) > 3 UNION SELECT T1.CountryId , T2.CountryName FROM countries AS T1 JOIN car_names AS T2 ON T1.CountryId = T2.Model WHERE T2.Make = 'FIAT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Ford\" GROUP BY T1.CountryId HAVING COUNT(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \" Fiat \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T2.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T2.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = 'ATL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" AND T1.DestAirport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'United Airlines' AND T2.DestAirport = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T1.airline = \"United Airlines\" AND T2.countryabbreviation = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'United Airlines' AND T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'Aberdeen' AND T1.Airline = 259", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" AND T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T1.Airline = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T1.Airline = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG' INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT airline FROM flights WHERE sourceairport = 'CVO' EXCEPT SELECT airline FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T2.FlightNo FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = 'Aberdeen' OR T1.city = 'Abilene'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop WHERE number_products = (SELECT max(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM hiring GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT count(*) , Hometown FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course_Name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT Name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_OF_MEMBERSHIP != \"LV 4\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name , T2.Level_of_membership FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T2.Total_spent = (SELECT max(T2.Total_spent) FROM visit AS T2 WHERE T2.Museum_ID = 'Museum A')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.museum_id , T1.name FROM museum AS T1 JOIN visit AS T2 ON T1.museum_id = T2.museum_id GROUP BY T1.museum_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = 'Lv1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T2.loser_age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.winner_rank_points FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_name ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank + T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id WHERE T2.tours = 'Australian Open' ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1\nSELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id AND T1.loser_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"right\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = 'left' AND T1.tourney_name = 'WTA Championships'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'Lost' AND T1.latin_commander = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name LIKE \"%math%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM Addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T3.last_name FROM students AS T3 JOIN student_enrolment AS T4 ON T3.student_id = T4.student_id JOIN degree_programs AS T5 ON T4.degree_program_id = T5.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE permanent_address_id IN (SELECT T1.line_1 , T1.state_province_county FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permpermanent_address_id WHERE T1.state_province_county = \"North Carolina\") EXCEPT SELECT T2.last_name FROM students AS T2 JOIN student_enrolment AS T3 ON T2.student_id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id WHERE T2.degree_program_id = 'BACHELOR' ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Transcripts AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id ORDER BY T3.transcript_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.section_name FROM Sections AS T1 JOIN Student_Enrolment AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.section_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.perminent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Master' INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT semester_id FROM student_enrolment WHERE degree_program_id = 'Masters' INTERSECT SELECT semester_id FROM student_enrolment WHERE degree_program_id = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN courses AS T3 ON T2.state_province_county = T3.course_id WHERE T2.country = 'Haiti' OR T1.cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id IN (SELECT T1.permanent_address_id FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.country = \"Haiti\") OR cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.country = \"USA\" AND T1.write_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.series_name FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel JOIN tv_series AS T3 ON T3.id = T2.episode WHERE T2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T2.series_name FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE content = \"Sky Radio\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Air_Date FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT original_air_date FROM cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.channel FROM TV_channel AS T1 JOIN tv_series AS T2 ON T1.id = T2.channel WHERE T1.content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HDTV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.title = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel EXCEPT SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM TV_channel WHERE language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T2.package_option FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Money_Rank , Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T1.Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T1.Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT count(*) , Nationality FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T2.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T1.contestant_number FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling') INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T1.contestant_number FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Name = \"Carribean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE countrycode = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.region FROM country AS T1 JOIN city AS T2 ON T1.capital = T2.population WHERE T2.name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.region FROM country AS T1 JOIN city AS T2 ON T1.capital = T2.population WHERE T2.name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = \"ARUBA\" GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.region , T1.population FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code WHERE T2.name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.region , T1.population FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(T1.Population) , max(T2.GNP) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Africa\" AND region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE name = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America' OR continent = 'South America' OR continent = 'Central America' OR continent = 'South America' OR continent = 'South America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "{\"sql\": \"SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America' OR continent = 'South America' OR continent = 'Central America' OR continent = 'West America' OR continent = 'East America' OR continent = 'Pacific' OR continent = 'Maritime Asia' OR continent = 'Antarctic' OR continent = 'South Pacific' OR continent = 'Indian Ocean' OR continent = 'Atlantic' OR continent = 'Pacific Asia' OR continent = 'Mediterranean' OR continent = 'Southern Pacific' OR continent = 'Southern Asia' OR continent = 'Southern Europe' OR continent = 'Eastern Europe' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Southern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern Asia' OR continent = 'Central Asia' OR continent = 'Eastern", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND code = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND countrycode = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t1.continent ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"english\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"english\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"french\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE t1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.language = \"English\" OR T1.language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.language = \"Dutch\" OR T1.language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 OR T2.language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE continent = 'Asia' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.name = \"Asia\" GROUP BY T2.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.countrycode = t2.countrycode WHERE t2.Language = \"English\" GROUP BY t1.name ORDER BY sum(t1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT isofficial) FROM countrylanguage WHERE independyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM countrylanguage EXCEPT SELECT countrycode FROM countrylanguage WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE isofficial = 0 AND language != 'english' AND countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE Continent != \"Asia\" AND Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0 AND language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.isofficial = 1 AND T1.countrycode = (SELECT countrycode FROM country WHERE continent = \"Asia\" AND language = \"Chinese\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.language = \"Chinese\" AND T1.continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT population , name , headofstate FROM country ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = \"Europe\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Population) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"North America\" AND T1.SurfaceArea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000 - 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.CountryCode , T1.Percentage FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T2.CountryCode ORDER BY SUM(T1.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(language) FROM countrylanguage WHERE percentage = (SELECT max(percent) FROM countrylanguage)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT DISTINCT grade FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , year FROM highschooler GROUP BY year", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name , grade FROM Highschooler GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 219487", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM FRIEND AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 1015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T3.email_address > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code MINUS SELECT T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T1.cost_of_treatment = (SELECT min(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.treatment_type_description FROM treatments AS t1 JOIN treatment_types AS t2 ON t1.treatment_type_code = t2.treatment_type_code ORDER BY cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.professional_id HAVING avg(T2.size_description) < (SELECT min(size_description) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , count(*) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT COUNT(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , MAX(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(net_workillions) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING SUM(T2.Sales) > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..75aa191b27972ee0b134b2fa4bd4e7b94d3543aa --- /dev/null +++ b/infer/qwen/spider_realistic/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_ID = T3.concert_ID GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE t2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE t2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T2.pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID WHERE T2.pettype = \"Cat\" OR T2.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" INTERSECT SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.pet_id = T2.pet_id WHERE T2.pet_age > 10)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_age = 8 EXCEPT SELECT T1.Major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_age = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE pet_type = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.Fname , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"dog\") EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T1.Model FROM car_models AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T1.MPG < (SELECT avg(MPG) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT t2.Model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.Id = t2.MakeId WHERE t1.Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.Model WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.year FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid WHERE T2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.Model WHERE T2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.FullName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = (SELECT make FROM car_makers GROUP BY make ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'Amharthornet Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryname WHERE continent = 'france'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryname WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN car_names AS T3 ON T2.model = T3.model WHERE T3.countryname = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 4 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Country FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T3.CountryName , T1.Id FROM car_makers AS T1 JOIN cars_data AS T2 JOIN countries AS T3 ON T1.Id = T2.Id AND T2.Model = T3.Model GROUP BY T1.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "{\"sql\": \"SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \\\"Toyota\\\" AND T2.Maker = \\\"Ford\\\" AND T2.Maker = \\\"BMW\\\" AND T2.Maker = \\\"Chevrolet\\\" AND T2.Maker = \\\"Honda\\\" AND T2.Maker = \\\"Tesla\\\" AND T2.Maker = \\\"Nissan\\\" AND T2.Maker = \\\"Maruti Suzuki\\\" AND T2.Maker = \\\"Mersedu\\\" AND T2.Maker = \\\"Peugeot\\\" AND T2.Maker = \\\"Porsche\\\" AND T2.Maker = \\\"VW\\\" AND T2.Maker = \\\"VW\\\" AND T2.Maker = \\\"Volkswagen\\\" AND T2.Maker = \\\"BMW\\\" AND T2.Maker = \\\"Chrysler\\\" AND T2.Maker = \\\"Toyota\\\" AND T2.Maker = \\\"Ford\\\" AND T2.Maker = \\\"Nissan\\\" AND T2.Maker = \\\"Maruti Suzuki\\\" AND T2.Maker = \\\"Mersedu\\\" AND T2.Maker = \\\"Peugeot\\\" AND T2.Maker = \\\"Porsche\\\" AND T2.Maker = \\\"VW\\\" AND T2.Maker = \\\"Volkswagen\\\" AND T2.Maker = \\\"Chevrolet\\\" AND T2.Maker = \\\"Honda\\\" AND T2.Maker = \\\"Tesla\\\" AND T2.Maker = \\\"Nissan\\\" AND T2.Maker = \\\"Maruti Suzuki\\\" AND T2.Maker = \\\"Mersedu\\\" AND T2.Maker = \\\"Peugeot\\\" AND T2.Maker = \\\"Porsche\\\" AND T2.Maker = \\\"VW\\\" AND T2.Maker = \\\"Volkswagen\\\" AND T2.Maker = \\\"Chevrolet\\\" AND T2.Maker = \\\"Honda\\\" AND T2.Maker = \\\"Tesla\\\" AND T2.Maker = \\\"Nissan\\\" AND T2.Maker = \\\"Maruti Suzuki\\\" AND T2.Maker = \\\"Mersedu\\\" AND T2.Maker = \\\"Peugeot\\\" AND T2.Maker = \\\"Porsche\\\" AND T2.Maker = \\\"VW\\\" AND T2.Maker = \\\"Volkswagen\\\" AND T2.Maker = \\\"Chevrolet\\\" AND T2.Maker = \\\"Honda\\\" AND T2.Maker = \\\"Tesla\\\" AND T2.Maker = \\\"Nissan\\\" AND T2.Maker = \\\"Maruti Suzuki\\\" AND T2.Maker = \\\"Mersedu\\\" AND T2.Maker = \\\"Peugeot\\\" AND T2.Maker = \\\"Porsche\\\" AND T2.Maker = \\\"VW\\\" AND T2.Maker = \\\"Volkswagen\\\" AND T2.Maker = \\\"Chevrolet\\\" AND T2.Maker = \\\"Honda\\\" AND T2.Maker = \\\"Tesla\\\" AND T2.Maker = \\\"Nissan\\\" AND T2.Maker = \\\"Maruti Suzuki\\\" AND T2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" GROUP BY T2.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT t1.Model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.Id = t2.MakeId ORDER BY t1.MPG LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId ORDER BY T1.MPG LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.Make FROM car_makers AS t1 JOIN car_names AS t2 ON t1.Model = t2.Model GROUP BY t1.Make ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model JOIN car_makers AS T3 ON T2.Maker = T3.Id WHERE T3.Maker = \"General Motors\" UNION SELECT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model JOIN car_makers AS T3 ON T2.Maker = T3.Id WHERE T3.Maker = \"General Motors\" OR T2.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.weight > 3500 JOIN car_makers AS T3 ON T3.id = T2.make WHERE T3.fullName = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(Cylinders) FROM cars_data WHERE accelerate = (SELECT min(Accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND make = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers WHERE make > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Cylinders = 4 GROUP BY T2.Model ORDER BY AVG(Horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Weight > 3500 EXCEPT SELECT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model JOIN car_makers AS T3 ON T2.Maker = T3.Id WHERE T3.FullName = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.MakeId WHERE T2.fullname = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryH > 3 UNION SELECT T3.Id , T2.CountryName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.MakeID JOIN car_names AS T3 ON T2.Model = T3.Model WHERE T3.Make = \"Fiat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryID HAVING count(*) > 3 UNION SELECT CountryId , CountryName FROM cars_data AS T3 JOIN car_names AS T4 ON T3.MakeId = T4.ModelId JOIN model_list AS T5 ON T4.Model = T5.Model WHERE T5.Model = \" Fiat \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Abbreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.AirportCode = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\" INTERSECT SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\" AND T2.destairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline WHERE T2.Abreviation = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline WHERE T2.Abbreviation = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abreviation = 'United Airlines' AND T2.DestAirport = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DESTAirport = T2.AirportCode JOIN airlines AS T3 ON T1.Airline = T3.UID WHERE T3.Abbreviation = \"United\" AND T2.City = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abreviation = 'United Airlines' AND T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abn = 'United Airlines' AND T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.airportname = 'Aberdeen' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DESTAirport = T2.AirportCode JOIN airlines AS T3 ON T1.Airline = T3.UID WHERE T3.Abbreviation = \"United\" AND T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.FlightNo = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.SourceAirport WHERE T1.Abbreviation = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.SourceAirport WHERE T1.Abbreviation = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.SourceAirport WHERE T1.Abbreviation = 'CVO' EXCEPT SELECT DISTINCT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.SourceAirport WHERE T1.Abbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "{\"sql\": \"SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n SELECT T1.FLIGHTNO FROM flights AS T1 JOIN ( \\n )) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) ) } ) } ) } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } } }", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.Airline , T1.FLIGHTNO FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DESTAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DESTAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\" OR T1.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights) AND NOT IN (SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights) - (SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT LOCATION , count(*) FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY Number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T2.bonus = (SELECT max(bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T3.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id JOIN employee AS T3 ON T1.employee_id = T3.employee_id GROUP BY T2.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM shop AS t1 JOIN hiring AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT T2.Hometown , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T3.Course_ID = T1.Course_ID WHERE T3.Course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership != 'Lv 4'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.museum_id , T2.name , T2.membership_level FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_ID GROUP BY T2.museum_id ORDER BY sum(T2.total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.name FROM visitor AS T1 JOIN museum AS T2 ON T1.id = T2.num_of_staff WHERE T1.level_of_membership = \"Public\" GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum EXCEPT SELECT T2.name FROM visitor AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.Total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T1.level_of_membership = 'Lv 1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2013 INTERSECT SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tournament_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tournament_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tournament_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tournament_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT t1.winner_name FROM players AS t1 JOIN matches AS t2 ON t1.player_id = t2.winner_id WHERE t2.tourney_name = \"Australian Open\" ORDER BY t2.winner_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT t1.winner_name FROM players AS t1 JOIN matches AS t2 ON t1.player_id = t2.winner_id WHERE t2.tourney_name = \"Australian Open\" ORDER BY t2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT loser_name , winner_name FROM matches ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"right\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'lost' AND T1.latin_commander = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT DISTINCT course_description FROM COURSES WHERE course_name = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT DISTINCT course_description FROM COURSES WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id JOIN degree_programs AS T3 ON T3.degree_program_id = T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE permanent_address_id IN (SELECT address_id FROM addresses WHERE state_province_county = \"North Carolina\") EXCEPT SELECT T2.last_name FROM students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT T2.cell_mobile_number FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Timmothy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_enrolment_id WHERE T2.transcript_date = (SELECT max(transcript_date) FROM Transcripts)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_id , T1.section_name FROM student_enrolment AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.section_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Master' INTERSECT SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_id FROM degree_programs AS T1 JOIN student_enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T1.degree_summary_name = 'Masters' INTERSECT SELECT T2.semester_id FROM degree_programs AS T1 JOIN student_enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T1.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN courses AS T3 ON T2.state_province_county = T3.state_province_county WHERE T2.country = \"Haiti\" OR T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id IN (SELECT address_id FROM addresses WHERE country = \"Haiti\") AND cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM cartoon ORDER BY Title ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM Cartoon ORDER BY Title ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.channel WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM tv_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM tv_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM tv_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T1.Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE content = 'Sky Radio' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.Channel = T2.Channel WHERE T2.Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series ORDER BY Weekly_Rank DESC LIMIT 1 WHERE Series_Name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.episode FROM tv_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_Channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = 'HDTV'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel JOIN TV_series AS T3 ON T3.id = T2.directed_by WHERE T2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_channel WHERE id NOT IN (SELECT Channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t2.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.channel WHERE t1.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Ben Jones' INTERSECT SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT Channel FROM TV_channel EXCEPT SELECT Channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM tv_channel EXCEPT SELECT t1.package_option FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon) AND directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM People WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM People WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T1.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT DISTINCT T1.state FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T1.contestant_number FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = \"Tabatha Gehling\" INTERSECT SELECT T1.contestant_number FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = \"Kelly Clauss\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independeyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT region) FROM country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT country) FROM city", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t2.SurfaceArea) FROM country AS t1 JOIN city AS t2 ON t1.CountryCode = t2.CountryCode WHERE t1.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN country AS t2 ON t1.code = t2.code WHERE t1.name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.name = \"Aruba\" GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE name = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE region = \"Republic\" AND countrycode IN (\"CA\",\"SG\",\"JO\",\"IN\",\"MR\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR region = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "{\"sql\": \"SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America' OR continent = 'South America' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Africa' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = 'Europe' OR continent = 'Americas' OR continent = 'Africa' OR continent = 'Asia' OR continent = 'Oceania' OR continent = '", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(T1.Percentage) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.country = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country.code = \"AF\" AND isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN country AS T3 ON T3.Code = T2.IsOfficial WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN country AS T3 ON T3.Code = T2.IsOfficial WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" OR T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode JOIN country AS T3 ON T2.isofficial = 1 WHERE T2.Language = \"English\" GROUP BY T1.name ORDER BY sum(T1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.countrycode = t2.countrycode WHERE t2.Language = \"English\" GROUP BY t1.name ORDER BY sum(t2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code WHERE T1.continent = 'Asia' ORDER BY T1.surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T1.Capital = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.indepyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT IsOfficial) FROM countrylanguage WHERE independYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE region = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'African' AND population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'African' INTERSECT SELECT name FROM country WHERE population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT name FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT name FROM country WHERE population > (SELECT max(population) FROM country WHERE region = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE Language != \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\" ) AND region != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode = (SELECT code FROM countrylanguage WHERE language = 'English' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "{\"sql\": \"SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T1.name IN (SELECT T1.name FROM", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.continent = 'Asia' INTERSECT SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T3.IsOfficial = 1 AND T3.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , surfacearea FROM country ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indepyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.population , t1.name , t1.HeadOfState FROM city AS t1 JOIN country AS t2 ON t1.CountryCode = t2.Code ORDER BY t2.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population > 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population > 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Population) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"North America\" AND T2.SurfaceArea > 3000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 1600000 AND 900000 - 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY SUM(T1.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT countrycode , max(Percentage) FROM countrylanguage GROUP BY countrycode", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(t1.percentage) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t1.Language = \"Spanish\" ORDER BY t2.IsOfficial DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.Code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\" ORDER BY T2.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY countrycode ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE orchestra = \"CD\" OR orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE id = (SELECT id FROM highschooler WHERE name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , year FROM highschooler GROUP BY year", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , YEAR FROM highschooler GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM highschooler GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 1005 AND T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = (SELECT id FROM friend WHERE T3.name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.treatment_id , T1.professional_id , T2.first_name FROM treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type_code ORDER BY sum(T2.charge_amount) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN treatment_type_code AS T2 ON T1.treatment_type_code = T2 WHERE T2.cost_of_treatment = (SELECT min(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id JOIN treatments AS T3 ON T3.professional_id = T2.professional_id WHERE T3.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_wealth_millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_worth_millions) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..937f503147b970686c4d4c3316986962ddbce7e8 --- /dev/null +++ b/infer/qwen/spider_realistic/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium EXCEPT SELECT T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR != 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.songer_id = T2.songer_id GROUP BY T2.songer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.song_id = T2.song_id JOIN concert AS T3 ON T3.concert_id = T2.concert_id WHERE T3.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM pets ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT min(weight) FROM pets WHERE pettype = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM pets AS T1 JOIN has_pet AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T2.stuid = T3.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM pets AS T1 JOIN has_pet AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T2.stuid = T3.stuid WHERE T3.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet AS T1 JOIN student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = 'F' AND T1.pettype = \"D\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet AS T1 JOIN student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = 'F' AND T1.pettype = 'D'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'Cat' OR T3.pettype = 'Dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" OR T3.PetType = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'Cat' INTERSECT SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'Dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Dogs\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE pettype = \"Cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetType = \"Cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT fname , age FROM Student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID = \"dog\" EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT fname FROM student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID = \"dog\" EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'Cat' AND T1.age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'Cat' AND T1.age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.Fname , COUNT(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Name , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT Model FROM cars_data WHERE Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.Year FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.MakeId = T2.MakeId ORDER BY T1.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.fullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT avg(T1.accelerate) FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.id WHERE T2.country = 'Americano' AND T2.sw = 'Hornet'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE YEAR = 2004 AND Maker = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE YEAR = 2004", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT car_name FROM cars_data GROUP BY car_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.Maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.Maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Fname , T1.Lower FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T2.maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T1.id FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.id GROUP BY T1.id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" OR T1.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.id JOIN cars_data AS T3 ON T3.id = T2.Model WHERE T2.Maker = \"General Motors\" OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Cylinders) FROM cars_data WHERE Maker = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Cylinders) FROM cars_data WHERE Maker = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = \"8\" OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id WHERE T2.Maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id JOIN cars_data AS T3 ON T3.id = T2.model WHERE T3.weight < 3500 EXCEPT SELECT DISTINCT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id WHERE T2.Maker = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Country , COUNT(*) FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.Country HAVING COUNT(*) > 3 UNION SELECT T1.Country , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.CountryName = 'fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.countryid , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.countryid , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE AirportName = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE Country = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE Country = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Aberdeen\" AND destinationairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Aberdeen\" AND destinationairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = 'United Airlines' AND T2.destairport = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"United Airlines\" AND T2.destairport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airline = \"United Airlines\" AND T2.sourceairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airline = \"United Airlines\" AND T2.sourceairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = 'United Airlines' AND T2.destairport = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airline = \"United Airlines\" AND T2.sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T2.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Source Airport WHERE T2.Source Airport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T2.sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.SourceAirport WHERE T2.City = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Source Airport WHERE T2.City = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.FlightLine WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.FlightLine WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SOURCE Airport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SOURCE Airport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\" OR T1.city = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = \"Aberdeen\" OR T1.city = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights) INTERSECT SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DestAirport FROM flights) OR AirportCode NOT IN (SELECT SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM store WHERE number_products > (SELECT avg(number_products) FROM store)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM shop AS T1 JOIN hiring AS T2 ON T1.shop_id = T2.shop_id GROUP BY T2.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown = 32 OR Hometown = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID WHERE T1.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT Name FROM visitor WHERE Age > 4 ORDER BY LEVEL_OF_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_OF_membership > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT Museum_ID , Name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T1.id , T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name , T1.level_of_membership FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id ORDER BY sum(T2.total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Museum_ID , T1.Name FROM museum AS T1 JOIN visit AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE Num_of_Staff = 'null'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(total_expent) FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tournament_name FROM matches GROUP BY tournament_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT T2.tourney_name FROM matches AS T1 JOIN tournaments AS T2 ON T1.tourney_id = T2.tourney_id GROUP BY T1.tourney_id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.winning_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T2.winning_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winning_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winning_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winning_rank , sum(T2.winning_rank_points) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winery_NAME FROM MATCHES AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.rank = T3.player_id WHERE T3.tourney_name = 'Australian Open' ORDER BY T1.winery_NAME DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winery_NAME FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.loser_id = T3.player_id WHERE T3.tourney_name = 'Australian Open' ORDER BY T3.winery_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T2.winery_NAME , T2.winery_Rank FROM MATCHs AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.loser_age DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T2.winery_NAME , T2.winery_Rank FROM MATCHES AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winery_Rank ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T2.winner_id) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"WTA Championships\" INTERSECT SELECT count(DISTINCT T2.winer_id) FROM matches AS T1 JOIN players AS T2 ON T1.winer_id = T2.player_id WHERE T1.tourney_name = \"Left Handed\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM left-handed players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.ranker_id = T3.player_id WHERE T3.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T2.caused_by_ship_id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT name , date FROM battle WHERE result = 'Loss' AND Latin_commander = 'Lettice' AND HMS_Atantana = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT lost_in_battle FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT T2.department_description FROM courses AS T1 JOIN departments AS T2 ON T1.course_id = T2.course_id WHERE T2.department_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN student_enrolment AS T2 ON T1.address_id = T2.address_id JOIN degree_program AS T3 ON T2.student_id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN student_enrolment AS T2 ON T1.address_id = T2.address_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT semester_id FROM Student_Enrolment WHERE student_id = 'Master' INTERSECT SELECT semester_id FROM Student_Enrolment WHERE student_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT semester_id FROM Student_Enrolment WHERE degree_program_id = \"MA\" INTERSECT SELECT semester_id FROM Student_Enrolment WHERE degree_program_id = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Haiti\" OR T2.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Haitt\" UNION SELECT first_name FROM students WHERE cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE written_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE LANGUAGE = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t1.title FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT weekly_rank FROM TV_series WHERE series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.Sky Radio = \"\"\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Episode FROM TV_series WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM Cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM Cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_CHANNEL WHERE high_definition_tv = 'HD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE high_definition_tv = 'HDTV'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T2.country FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2_written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2_written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT pixel_aspect_ratio_par , country FROM TV_CHANNEL WHERE language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT pixel_aspect_ratio_par , country FROM TV_CHANNEL WHERE language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel WHERE country > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T1.package_option FROM TV_channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T1 package_option FROM TV_channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Money_Rank DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM votes WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM votes AS T1 JOIN area_code_state AS T2 ON T1.state = T2.state WHERE T2.state = 'NY' OR T2.state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T1.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_name = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM city", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t1.surfacearea) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t2.district = \"Carribean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.region FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT region FROM city WHERE name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'Aruba' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'Aruba' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE countrycode = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE countrycode = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT region , population FROM city WHERE countrycode = \" Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.District , T1.population FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \" Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE countrycode IN (SELECT countrycode FROM country WHERE lifeexpectancy = (SELECT min(lifeexpectancy) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(gnp) , sum(population) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(t1.lifeexpectancy) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.isofficial = 'A' AND t1.name = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(t1.lifeexpectancy) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code WHERE t2.countrycode = 'Africa' AND t1.isofficial = 'R'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT count(*) FROM city WHERE name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT gnp) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(t1.languages) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = 'Afghanistan' AND isofficial = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = t2.countrycode WHERE T1.name = \"Afghanistan\" AND T2.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Countname FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.Countname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Countcontinent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.Countcontinent ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'English' INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'English' INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.count) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.clont) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT T1.region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = 'english' OR T2.language = 'dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT T1.region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = 'Dutch' OR T2.language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 'English' OR T2.isofficial = 'Dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE isofficial = 'Yes' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.isofficial = 'A' GROUP BY T1.language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = (SELECT countrycode FROM country GROUP BY countrycode HAVING count(*) = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.isofficial = 'Y' AND T2.headofstate = 'N'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.CountryCode WHERE T3.language = \"english\" GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT max(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.languages = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(t1.lifeexpectancy) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.isofficial = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(t1.lifeexpectancy) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.isofficial = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(GNP) FROM country WHERE language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.head_of_state = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"Beatrix\" AND T2.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(t1.language) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.founded < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(T1.GNP) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.indep_year < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Afghanistan') AND country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE isofficial = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country WHERE isofficial = 'No' EXCEPT SELECT countrycode FROM countrylanguage WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T2.isofficial = 'No' AND T3.language = 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT t1.name FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code JOIN countrylanguage AS t3 ON t2.code = t3.countrycode WHERE t2.isofficial = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T2.isofficial = 'Yes' AND T2.region = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indepyear , surfacearea FROM country ORDER BY gnp LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indep_year , surfacearea FROM country ORDER BY population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT population , name , head_of_state FROM country ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT T2.name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code ORDER BY T1.population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND GNP > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2continent = 'Noth America' AND t1.population > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population > 160000 AND population < 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT Name FROM city WHERE Population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT language , countrycode , percentage FROM countrylanguage ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.code , T2.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Spanish\" ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT code2 FROM countrylanguage ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY Year_of_Founded ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , T1.year FROM Highschooler AS T1 JOIN Student AS T2 ON T1.id = T2.id GROUP BY T1.year", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , T1.year FROM Highschooler AS T1 JOIN Student AS T2 ON T1.id = T2.id GROUP BY T1.year", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM Highschooler GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.friend_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(T2.friend_id) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(T2.friend_id) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) > 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T2.grade) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.friend_id != \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T1.owner_id = T3.owner_id WHERE T3.city > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.dog_id , T1.role_code , T2.first_name FROM doctors AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.dog_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.treatment_id , T1.role_code , T2.first_name FROM Treatment_Types AS T1 JOIN Owners AS T2 ON T1.professional_id = T2.owner_id GROUP BY T1.treatment_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.cost_of_treatment ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.cost_of_treatment ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.dog_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.total_charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.total) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_area < (SELECT avg(treatment_area) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE home_phone = 'Hawaii' OR home_phone = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE home_phone = 'Hawaii' OR home_phone = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 'yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 'yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT COUNT(*) , Country FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT Country FROM singer GROUP BY Country HAVING COUNT(*) = \"MO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(Net_Worth_Millions) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(Net_Worth_Millions) , Country FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'HSE' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..909bbba362409fd5dd34f94ea7c7e4a3b441cc69 --- /dev/null +++ b/infer/qwen/spider_realistic/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT Name, Country, Age FROM singer ORDER BY Age DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Age), min(Age), max(Age) FROM singer WHERE Country = \"France\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age), min(age), max(age) FROM singer WHERE country = \"France\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer WHERE Age = (SELECT min(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT average(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT Location , Name FROM stadium WHERE Capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT Location , Name FROM stadium WHERE Capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT Name FROM stadium WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_Name , T1.Theme , (SELECT count(*) FROM singer_in_concert AS T2 WHERE T2.concert_ID = T1.concert_ID ) FROM concert AS T1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.concert_Name , T2.concert_ID FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T2.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id WHERE T3.year = 2014;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT DISTINCT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id WHERE T3.year = 2014;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT Name , Country FROM singer WHERE Song_Name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.stadium_id , T1.location , T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.stadium_id , T1.location , T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM stadium ORDER BY capacity DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM stadium ORDER BY capacity DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM pets WHERE pet_type = 'dog' AND pet_age = (SELECT min(age) FROM student)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(age) FROM Student)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Age > 20);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Age > 20);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet WHERE StuID IN (SELECT StuID FROM student WHERE sex = 'F');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE sex = 'F');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"cat\" OR T3.pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'cat' OR T3.pet_type = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT fname FROM student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = 'cat') INTERSECT SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = 'dog'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Major , Age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT stuid FROM has_pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = \"cat\"));", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.petid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'dog' AND T3.petid NOT IN (SELECT petid FROM has_pet WHERE petid IN (SELECT petid FROM pets WHERE pettype = 'cat'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'dog' EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'cat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM Pets ORDER BY pet_age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM pets WHERE pet_age = (SELECT min(pet_age) FROM pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT pet_id , weight FROM pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT pet_id , weight FROM pets WHERE pet_age > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT DISTINCT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT stuid FROM has_pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE stuID NOT IN (SELECT stuID FROM has_pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id , count(model_list.modelid) FROM car_makers JOIN model_list ON car_makers.id = model_listmaker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id , count(model_list.Maker) FROM car_makers JOIN model_list ON car_makers.id = model_list.Maker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT maker FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM model_list WHERE Id IN (SELECT MakeId FROM cars_data WHERE Weight < (SELECT avg(Weight) FROM cars_data));", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT car_makers.Maker FROM car_makers JOIN cars_data ON car_makers.Id = cars_data.MakeId WHERE cars_data.Year = 1970;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Id WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T1.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Id ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT car_makers.Maker , cars_data.Year FROM car_makers JOIN cars_data ON car_makers.Id = cars_data.Id ORDER BY cars_data.Year ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT model FROM model_list WHERE maker NOT IN (SELECT maker FROM cars_data WHERE YEAR <= 1980)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT model FROM model_list JOIN cars_data ON model_list maker = cars_data.id WHERE cars_data.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT COUNT(*) , car_makers.fullname FROM car_makers JOIN model_list ON car_makers.id = model_listmaker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , car_makers.id , car_makers.fullname FROM car_makers JOIN model_list ON car_makers.id = model_listmaker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT Accelerate FROM cars_data WHERE Id = (SELECT MakeId FROM car_names WHERE Model = \"amc hornet sportabout (sw)\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(DISTINCT Id) FROM car_makers WHERE Country = (SELECT CountryId FROM countries WHERE Continent = 'Europe');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT COUNT(DISTINCT car_makers.Id) FROM car_makers JOIN countries ON car_makers.Country = countries.CountryId WHERE countries.Continent = \"Europe\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers WHERE country IN (SELECT countryid FROM countries WHERE continent = 'USA')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers JOIN countries ON car_makers.Country = countries.CountryId WHERE countries.Continent = \"Americas\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE year = 1974 AND cylinders = 8;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT DISTINCT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT DISTINCT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING count(*) >= 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName HAVING COUNT(*) >= 3 INTERSECT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = 'Europe' GROUP BY T1.CountryName HAVING COUNT(*) >= 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id ORDER BY T2.MPG DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data JOIN car_names ON cars_data.Id = car_names.MakeId JOIN car_makers ON car_names.Maker = car_makers.Id JOIN countries ON car_makers.Country = countries.CountryId WHERE countries.Continent = 'Europe';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Id IN (SELECT MakeId FROM car_names INTERSECT SELECT Id FROM car_names WHERE MakeId IN (SELECT Id FROM car_makers WHERE Country = \"Sweden\"))", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.MakeId , T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.MakeId = T2.Id GROUP BY T1.MakeId ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers WHERE country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id FROM car_makers JOIN model_list ON car_makers.id = model_list.maker GROUP BY car_makers.id HAVING count(*) > 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.MakeName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker JOIN cars_data AS T3 ON T3.Id = T2.Makeid WHERE T1.Country = 'USA' OR T3.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE country = \"United States\" UNION SELECT maker FROM model_list WHERE modelid IN (SELECT id FROM cars_data WHERE weight > 3500)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE MakeId = (SELECT MakeId FROM cars_data ORDER BY Accelerate LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE MakeId IN ( SELECT Id FROM car_makers WHERE Country = 'Sweden' ) ORDER BY Accelerate ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT COUNT(DISTINCT country) FROM car_makers WHERE country IN (SELECT country FROM car_makers GROUP BY country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT COUNT(DISTINCT countryname) FROM countries WHERE countryid IN (SELECT DISTINCT country FROM car_makers GROUP BY country HAVING count(*) > 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT Model FROM cars_data WHERE Cylinders = 4 ORDER BY Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR Year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T1.model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN car_makers AS T3 ON T2.maker = T3.id WHERE T3.country = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.modelid = T2.id WHERE T2.weight < 3500 EXCEPT SELECT DISTINCT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1maker = T2.id JOIN cars_data AS T3 ON T3.id = T1.modelid WHERE T3.weight < 3500 AND T2.fullname = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT countryid , countryname FROM countries WHERE countryid IN (SELECT id FROM car_makers GROUP BY country HAVING count(*) > 3 UNION SELECT country FROM car_makers WHERE fullname = 'fiat')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT countryid , countryname FROM countries WHERE countryid IN (SELECT country FROM car_makers GROUP BY country HAVING count(*) > 3 UNION SELECT country FROM car_names GROUP BY country HAVING count(*) > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline = \"JetBlue Airways\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Abbreviation = 'JET'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = 'Jetblue Airways';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = 'UAL';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = 'ATO';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = 'ATO';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE City LIKE '%Aberdeen%');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE City = 'Aberdeen');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.AirportName = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.AirportName = \"Aberdeen\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = (SELECT AirportCode FROM airports WHERE City = \"Aberdeen\") AND DestAirport = (SELECT AirportCode FROM airports WHERE City = \"Ashley\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = (SELECT AirportCode FROM airports WHERE City = \"Aberdeen\") AND DestAirport = (SELECT AirportCode FROM airports WHERE City = \"Ashley\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'JetBlue Airways';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'Jetblue Airways';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'United Airlines' AND DestAirport LIKE 'ASY%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'United Airlines' AND DestAirport = 'ASY';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'United Airlines' AND SourceAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'United Airlines' AND SourceAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.AirportName = 'Aberdeen' AND flights.Airline = 'United';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.AirportName = 'Aberdeen' AND flights.Airline = 'United';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT Airline FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE AirportName = \"AHD\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT Airline FROM flights WHERE SourceAirport = 'AHD' OR DestAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT Airline FROM flights WHERE DestAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = 'AHD' OR DestAirport = 'AHD' GROUP BY Airline", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = \"APG\" INTERSECT SELECT Airline FROM flights WHERE SourceAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = 'APG' INTERSECT SELECT Airline FROM flights WHERE SourceAirport = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = 'CVO' EXCEPT SELECT Airline FROM flights WHERE SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT Airline FROM flights WHERE SourceAirport = 'CVO' EXCEPT SELECT Airline FROM flights WHERE SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = APG", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE City = \"Aberdeen\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = (SELECT AirportCode FROM airports WHERE City = 'Aberdeen');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"ABZ\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = (SELECT AirportCode FROM airports WHERE City = 'Aberdeen');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport IN (SELECT AirportCode FROM airports WHERE City = 'Aberdeen' OR City = 'Abilene');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.City = 'Aberdeen' OR airports.City = 'Abilene';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights UNION SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportCode FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights UNION SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT Name FROM employee ORDER BY Age;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT Name FROM employee ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT City FROM employee WHERE Age < 30 GROUP BY City HAVING COUNT(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT Location , COUNT(*) FROM shop GROUP BY Location", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT COUNT(*) , Name FROM shop GROUP BY Name;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT Manager_name , District FROM shop ORDER BY Number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name, location, district FROM shop ORDER BY number_products DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT Name , Location , District FROM shop ORDER BY Number_products DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT employee.Name FROM employee JOIN evaluation ON employee.Employee_ID = evaluation.Employee_ID ORDER BY evaluation.Bonus DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM hiring GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM hiring GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT District FROM shop WHERE Number_products < 3000 INTERSECT SELECT District FROM shop WHERE Number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT District FROM shop WHERE Number_products < 3000 INTERSECT SELECT District FROM shop WHERE Number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown, COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T1.name FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.teacher_id = T2.teacher_id JOIN course AS T3 ON T2.course_id = T3.course_id WHERE T3.course = 'math';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT teacher.name FROM teacher JOIN course_arrange ON teacher.teacher_id = course_arrange.teacher_id JOIN course ON course_arrange.course_id = course.course_id WHERE course.course = 'math';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE Age < 30;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(Age) FROM visitor WHERE Level_of_membership <= \"LV4\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT Museum_ID , Name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year < 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T1.id , T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name , T1.level_of_membership FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T1.id ORDER BY sum(T2.total_spent) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Museum_ID , T1.name FROM museum AS T1 JOIN visit AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(Total_spent) FROM visit WHERE ID IN (SELECT ID FROM visitor WHERE Level_of_membership = \"lv 1\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name, birth_date FROM players WHERE country_code = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_id HAVING count(*) > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_id HAVING count(*) > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT DISTINCT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' AND T2.year = 1972 INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open' AND T2.year = 1972", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY (SELECT max(birth_date) FROM players) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.player_id , T1.first_name , T1.last_name , T1.hand , T1.birth_date , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.player_id , T1.first_name , T1.last_name , T2.ranking_points FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id ¼ T2.winner_id WHERE T2.tournament_name ¼ 'Australian Open' AND T2.winner_rank_points ¼ (SELECT max(winner_rank_points) FROM matches WHERE tournament_name ¼ 'Australian Open')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.winner_id = T3.player_id GROUP BY T1.winner_id ORDER BY sum(T3.ranking_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code, count(*) FROM players GROUP BY country_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT winner_id) FROM matches JOIN players ON matches.winner_id = players.player_id WHERE players.hand = 'Left' AND EXISTS (SELECT * FROM matches AS T1 JOIN players AS P1 ON T1.winner_id = P1.player_id WHERE P1.country_code = 'USA' AND T1.year = 1980)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM (SELECT DISTINCT winner_id FROM matches WHERE winner_hand = \"left\" AND tourney_name = \"WTA Championships\") AS T;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T2.killed > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT ship.id , ship.name FROM ship JOIN death ON ship.id = death.caused_by_ship_id GROUP BY ship.id ORDER BY sum(injured) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' OR T2.name = 'HMS Atalanta' AND T1.result = 'lost'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name, RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT lost_in_battle FROM ship WHERE location = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"math\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM Addresses WHERE city = \"Port Chelsea\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM Addresses WHERE city = \"Port Chelsea\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM Students WHERE current_address_id IN (SELECT address_id FROM Addresses WHERE state_province_county = \"North Carolina\") EXCEPT SELECT Students.last_name FROM Students JOIN Student_Enrolment ON Students.student_id = Student_Enrolment.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM Students WHERE permanent_address_id IN (SELECT address_id FROM Addresses WHERE state_province_county = \"North Carolina\") AND student_id NOT IN (SELECT student_id FROM Student_Enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 , T1.city , T1.zip_postcode , T1.state_province_county , T1.country FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Addresses.address_id , Addresses.line_1 , Addresses.line_2 FROM Students JOIN Addresses ON Students.current_address_id = Addresses.address_id GROUP BY Addresses.address_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Courses AS T3 ON T2.course_id = T3.course_id JOIN Student_Enrolment AS T4 ON T4.student_id = T1.student_id JOIN Degree_Programs AS T5 ON T4.degree_program_id = T5.degree_program_id WHERE T5.degree_summary_name = 'Master' INTERSECT SELECT T1.semester_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Courses AS T3 ON T2.course_id = T3.course_id JOIN Student_Enrolment AS T4 ON T4.student_id = T1.student_id JOIN Degree_Programs AS T5 ON T4.degree_program_id = T5.degree_program_id WHERE T5.degree_summary_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT semester_id FROM Student_Enrolment GROUP BY semester_id HAVING count(DISTINCT degree_program_id) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM Students WHERE permanent_address_id IN (SELECT address_id FROM Addresses WHERE country = 'Haiti') OR cell_mobile_number = '09700166582';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM Students WHERE permanent_address_id IN (SELECT address_id FROM Addresses WHERE country = 'Haiti') OR cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM Cartoon ORDER BY Title;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM Cartoon ORDER BY Title;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM TV_Channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM TV_Channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_Channel WHERE id IN (SELECT Channel FROM TV_series UNION SELECT Channel FROM Cartoon) AND series_name = 'Sky Radio';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_Channel WHERE Language = \"English\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_Channel WHERE Language = \"English\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT TV_Channel.series_name FROM TV_Channel JOIN Cartoon ON TV_Channel.id = Cartoon.Channel WHERE Cartoon.Title = \"The Rise of the Blue Beetle!\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Channel IN (SELECT id FROM TV_Channel WHERE series_name = \"Sky Radio\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Channel = (SELECT id FROM TV_Channel WHERE series_name = 'Sky Radio')}", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Title = 'A Love of a Lifetime';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE series_name = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series JOIN Cartoon ON TV_series.Channel = Cartoon.Channel WHERE Cartoon.Title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT TV_Channel.series_name FROM TV_Channel JOIN Cartoon ON TV_Channel.id = Cartoon.Channel WHERE Cartoon.Title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "{\n \"sql\": \"SELECT TV_Channel.series_name FROM TV_Channel JOIN Cartoon ON TV_Channel.id = Cartoon.Channel WHERE Cartoon.Title = \"\"\"\"A Love of a Lifetime\"\"\"\";\"\n}", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT id FROM TV_Channel WHERE series_name = \"Sky Radio\" UNION SELECT id FROM Cartoon WHERE Channel = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Episode FROM TV_series WHERE Channel IN (SELECT id FROM TV_Channel WHERE series_name = \"Sky Radio\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT Directed_by , COUNT(*) FROM Cartoon GROUP BY Directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT Directed_by , COUNT(*) FROM Cartoon GROUP BY Directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_Channel WHERE Hight_definition_TV = 'Yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , TV_Channel.series_name FROM TV_Channel JOIN TV_series ON TV_series.Channel = TV_Channel.id WHERE TV_Channel.Hight_definition_TV = 'Yes' UNION SELECT Package_Option , TV_Channel.series_name FROM TV_Channel JOIN Cartoon ON Cartoon.Channel = TV_Channel.id WHERE TV_Channel.Hight_definition_TV = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT Country FROM TV_Channel WHERE id IN (SELECT DISTINCT Channel FROM Cartoon WHERE Written_by = \"Todd Casey writes\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_Channel WHERE id IN (SELECT DISTINCT Channel FROM Cartoon WHERE Written_by = \"Todd Casey\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE written_by = \"Todd Casey writes\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_Channel WHERE id NOT IN (SELECT Channel FROM Cartoon WHERE Written_by = \"Todd Casey\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Directed_by = \"Ben Jones\" OR T2.Directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Directed_by = \"Ben Jones\" OR T2.Directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_Channel WHERE country IN (SELECT country FROM TV_Channel GROUP BY country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_Channel WHERE id NOT IN (SELECT Channel FROM Cartoon WHERE Directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_Channel WHERE id NOT IN (SELECT DISTINCT Channel FROM Cartoon WHERE Directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM Cartoon WHERE Directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM Cartoon WHERE Directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Money_Rank , Earnings FROM poker_player ORDER BY Earnings DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player JOIN people ON poker_player.People_ID = people.People_ID ORDER BY Height DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player JOIN people ON poker_player.People_ID = people.People_ID ORDER BY people.Height DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE people.People_ID -> people.People_ID -> people.Height > 200;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE people.People_ID -> people.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(DISTINCT People_ID) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM votes WHERE state = 'CA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT created , state , phone_number FROM votes JOIN contestants ON votes.contestant_number = contestants.contestant_number WHERE contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT state FROM VOTES WHERE contestant_number IN (SELECT contestant_number FROM CONTESTANTS WHERE contestant_name = 'Tabatha Gehling') INTERSECT SELECT state FROM VOTES WHERE contestant_number IN (SELECT contestant_number FROM CONTESTANTS WHERE contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Caribbean';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Carribean';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT Continent FROM country WHERE Code = 'AGY';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT Continent FROM country WHERE Code = 'AIA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = 'Kabul';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT region FROM country WHERE countrycode = \"AF\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE CountryCode = 'ABW' ORDER BY percentage DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage WHERE CountryCode = 'ABW' ORDER BY Percentage DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = 'Brazil';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = 'Brazil';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT Region, Population FROM country WHERE Code = 'ANG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT Region , Population FROM country WHERE Name = 'Angola';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = 'Africa' AND Region = 'Central';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT LifeExpectancy FROM country WHERE Continent = 'Africa' AND Region = 'Central';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Asia' ORDER BY LifeExpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Asia' ORDER BY LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(population) , max(gnp) FROM country WHERE continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE Continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = 'Africa' AND GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = 'Africa' AND GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE Name LIKE 'United States' OR Code2 LIKE 'US';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE Name = 'United States';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT Language) FROM countrylanguage WHERE CountryCode = 'ABW';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT Language) FROM countrylanguage WHERE CountryCode = 'ABW';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT Code) FROM countrylanguage WHERE IsOfficial = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT IsOfficial) FROM countrylanguage WHERE CountryCode = 'AFG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Code ORDER BY COUNT(DISTINCT T2.Language) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Code ORDER BY COUNT(DISTINCT T2.Language) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(DISTINCT T2.Language) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT continent FROM countrylanguage GROUP BY continent ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT name FROM country WHERE code IN (SELECT countrycode FROM countrylanguage WHERE language = 'English' INTERSECT SELECT countrycode FROM countrylanguage WHERE language = 'French');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT name FROM country WHERE code IN (SELECT countrycode FROM countrylanguage WHERE language = 'English' INTERSECT SELECT countrycode FROM countrylanguage WHERE language = 'French') GROUP BY code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM country WHERE code IN (SELECT code FROM countrylanguage WHERE isofficial = 1 GROUP BY code HAVING count(DISTINCT language) = 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM country WHERE code IN (SELECT code FROM countrylanguage WHERE isofficial = 1 AND language = 'English' INTERSECT SELECT code FROM countrylanguage WHERE isofficial = 1 AND language = 'French');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT continent) FROM countrylanguage WHERE language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT COUNT(DISTINCT continent) FROM countrylanguage JOIN country ON countrylanguage.countrycode = country.code WHERE language = 'Chinese';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT region FROM countrylanguage WHERE language = 'English' OR language = 'Dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT region FROM countrylanguage WHERE language = 'Dutch' OR language = 'English';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT Name FROM country WHERE Code IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'english') UNION SELECT Name FROM country WHERE Code IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'dutch')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE CountryCode IN (SELECT code FROM country WHERE continent = 'Asia') GROUP BY CountryCode ORDER BY sum(percentage) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT countrylanguage.Language FROM countrylanguage WHERE countrylanguage.CountryCode IN (SELECT Code FROM country WHERE continent = 'Asia') GROUP BY countrylanguage.Language ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode IN (SELECT code FROM country GROUP BY code HAVING count(*) = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT Language FROM countrylanguage WHERE CountryCode IN (SELECT Code FROM country WHERE Population > 10000000000 AND GovernmentForm = 'Republic') INTERSECT SELECT Language FROM countrylanguage WHERE CountryCode IN (SELECT Code FROM country WHERE Population > 10000000000 AND GovernmentForm = 'Republic') GROUP BY Language HAVING COUNT(DISTINCT CountryCode) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT district FROM city JOIN countrylanguage ON city.countrycode = countrylanguage.countrycode WHERE language = 'English' GROUP BY district ORDER BY sum(population) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT max(T1.population) FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.language = 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = 'Asia' ORDER BY SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'English');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'English');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "{\n \"sql\": \"SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'english');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT IsOfficial FROM countrylanguage WHERE CountryCode = (SELECT Code FROM country WHERE HeadOfState = 'Beatrix');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT IsOfficial FROM countrylanguage WHERE CountryCode = (SELECT Code FROM country WHERE HeadOfState = 'Beatrix');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT IsOfficial) FROM countrylanguage WHERE Code IN (SELECT Code FROM country WHERE IndepYear < 1930);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT IsOfficial) FROM countrylanguage WHERE CountryCode IN (SELECT Code FROM country WHERE IndepYear < 1930);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT max(SurfaceArea) FROM country WHERE Continent = 'Europe')}", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT max(SurfaceArea) FROM country WHERE Continent = 'Europe') AND Continent != 'Europe';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "{\n \"sql\": \"SELECT Name FROM country WHERE Continent = 'Africa' AND Population < (SELECT min(population) FROM country WHERE continent = 'Asia')\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT Name FROM country WHERE Population < (SELECT max(Population) FROM country WHERE Continent = 'Asia')) AND Continent = 'Africa';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT Name FROM country WHERE Population > (SELECT max(population) FROM country WHERE continent = 'Asia') AND continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "{\n \"sql\": \"SELECT Name FROM country WHERE Continent = 'Asia' AND Population > (SELECT max(population) FROM country WHERE continent = 'Africa')\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code FROM country WHERE Code NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = 'English') UNION SELECT Code FROM country WHERE IsOfficial = 'Yes' AND Language != 'English' AND CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = 'English')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code FROM country WHERE Code NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = 'English')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT Code FROM countrylanguage WHERE IsOfficial = 'T' AND Language != 'English';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT Code FROM country WHERE Code NOT IN (SELECT CountryCode FROM countrylanguage WHERE Language = 'English' AND IsOfficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code FROM country WHERE GovernmentForm != 'Republic' AND Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English' AND IsOfficial = 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code FROM country WHERE GovernmentForm != 'Republic' EXCEPT SELECT Code FROM countrylanguage WHERE Language = 'English' AND IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT DISTINCT city.name FROM city JOIN country ON city.CountryCode = country.Code WHERE country.continent = 'Europe' AND countrylanguage.IsOfficial = 'T' AND countrylanguage.Language != 'English' AND countrylanguage.CountryCode = city.CountryCode;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia' AND T2.Official = 'yes' INTERSECT SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia' AND T2.Official = 'yes' AND T2.Name = 'China'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia' AND CountryCode IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 'yes' AND Language = 'Chinese') ORDER BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.SurfaceArea , T1.IndepYear FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Code ORDER BY COUNT(DISTINCT T2.Language) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT Name , IndepYear , SurfaceArea FROM country ORDER BY Population LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT SurfaceArea , Name , HeadOfState FROM country ORDER BY Population DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city GROUP BY district HAVING avg(population) < count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Europe' AND Population > 80000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Europe' AND Population > 80000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population), avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(population) FROM country WHERE continent = 'North America' AND surfacearea > 3000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT Name FROM city WHERE Population BETWEEN 160000 AND 900000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT Name FROM city WHERE Population BETWEEN 160000 AND 900000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT country.Name , countrylanguage.Language , max(countrylanguage.Percentage) FROM country JOIN countrylanguage ON countrylanguage.CountryCode = country.Code GROUP BY country.Name;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT Code , Language FROM countrylanguage GROUP BY CountryCode ORDER BY max(percentage) DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode IN (SELECT code FROM countrylanguage GROUP BY countrycode ORDER BY percentage DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT COUNT(DISTINCT country.Code) FROM countrylanguage JOIN country ON countrylanguage.CountryCode = country.Code WHERE countrylanguage.IsOfficial = 'yes' AND countrylanguage.Language = 'Spanish';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT Code FROM countrylanguage WHERE Language = 'Spanish' ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT Code FROM countrylanguage WHERE Language = 'Spanish' AND IsOfficial = 'Yes' GROUP BY CountryCode HAVING SUM(Percentage) >= 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT COUNT(*) FROM orchestra WHERE Record_Company = \"CD\" OR Record_Company = \"DVD\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM Highschooler WHERE grade = 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM Highschooler WHERE grade = 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM Highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT grade FROM Highschooler GROUP BY grade;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT grade , count(*) FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.friend_id WHERE T2.student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle') INTERSECT SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM Friend JOIN Highschooler AS T2 ON T2.id = friend_id WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Friend WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Friend WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Likes WHERE student_id IN (SELECT id FROM Highschooler WHERE name = \"Kyle\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Likes WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(grade) FROM highschooler WHERE id IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(grade) FROM highschooler WHERE id IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM professionals WHERE state = 'Indiana' OR professional_id IN ( SELECT professional_id FROM treatments GROUP BY professional_id HAVING count(*) > 2 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = \"Indiana\" OR professional_id IN (SELECT professional_id FROM Treatments GROUP BY professional_id HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id GROUP BY T1.dog_id HAVING sum(T2.cost_of_treatment) > 1000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT DISTINCT T.professional_id , Professionals.role_code , Professionals.first_name FROM Treatments AS T JOIN Professionals ON T.professional_id = Professionals.professional_id GROUP BY T.professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM Treatment_Types WHERE treatment_type_code IN (SELECT treatment_type_code FROM Treatments GROUP BY treatment_type_code ORDER BY min(cost_of_treatment) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM Treatment_Types ORDER BY (SELECT min(charge_amount) FROM Charges) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN (SELECT treatment_type_code , avg(cost_of_treatment) AS avg_cost FROM Treatments GROUP BY treatment_type_code) AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T2.cost_of_treatment < T3.avg_cost", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Charges AS T3 ON T2.cost_of_treatment = T3.charge_amount WHERE T3.charge_type = 'max' EXCEPT SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Charges AS T3 ON T2.cost_of_treatment = T3.charge_amount WHERE T3.charge_type = 'min'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.name , T2.first_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs);", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship, COUNT(*) FROM singer GROUP BY Citizenship;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship, COUNT(*) FROM singer GROUP BY Citizenship;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship, max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'House' AND room_count > 1 UNION SELECT property_name FROM properties WHERE property_type_code = 'Apartment' AND room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_realistic/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_realistic/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..35cdc6e35e89e96e33d6fc52e6b29e6dbe3fcfe1 --- /dev/null +++ b/infer/qwen/spider_realistic/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,5590 @@ +[ + { + "sample_id": "spider_realistic:test:0", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, country, age for all singers from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:1", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all singers from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:2", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French singers?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:3", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the release year of the song by the youngest singer.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:4", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and release years for all the songs of the youngest singer?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT Song_Name , Song_release_year FROM singer ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:5", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct countries where singers older than 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:6", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different countries with singers older than 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:7", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show all countries and the number of singers in each nation.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:8", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many singers are from each nation?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:9", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all song names by singers older than average .", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:10", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the song names by singers who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:11", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show location and name for all stadiums that can fit between 5000 and 10000 people.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:12", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the locations and names of all stations that can accommodate between 5000 and 10000 fans?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:13", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts are there in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:14", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "How many concerts occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:15", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and capacity with most number of concerts in 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:16", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and capacity of the stadium with the most concerts after 2013?", + "gold_sql": "select t2.name , t2.capacity from concert as t1 join stadium as t2 on t1.stadium_id = t2.stadium_id where t1.year > 2013 group by t2.stadium_id order by count(*) desc limit 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:17", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any concert.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:18", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any concerts?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:19", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show countries where a singer older than 40 and a singer younger than 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:20", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a concert in 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:21", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a concert in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:22", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all concerts and the number of singers in each.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:23", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of concerts for each person.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:24", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and number of concerts for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:25", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "List all singer names in concerts in 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:26", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers who performed in a concert in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:27", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the singer who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:28", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and country of origin of every singer who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:29", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and location of the stadiums which some concerts happened in both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:30", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and locations of the stadiums that had concerts that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:31", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of concerts happened in the stadium that can accommodate the most people.", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE t2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:32", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of concerts that occurred in the stadium with space for the most people?", + "gold_sql": "select count(*) from concert where stadium_id = (select stadium_id from stadium order by capacity desc limit 1)", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:33", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of pets that is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:34", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are over 10 lbs?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:35", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest dog.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:36", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest dog weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:37", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find number of pets owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:38", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many pets are owned by students that are older than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:39", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of dogs that are raised by female students.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T1.sex = 'F' AND T3.pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:40", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "How many dogs are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:41", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name of students who have cat or dog.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:42", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the first names of every student who has a cat or dog?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:43", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both cat and dog.", + "gold_sql": "select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'cat' intersect select t1.fname from student as t1 join has_pet as t2 on t1.stuid = t2.stuid join pets as t3 on t3.petid = t2.petid where t3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Pets AS T2 ON T1.Stuid = T2.Stuid WHERE T2.pettype = \"Cat\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Pets AS T2 ON T1.Stuid = T2.Stuid WHERE T2.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:44", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' first names who have both cats and dogs?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:45", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a cat.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:46", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What major is every student who does not own a cat, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = Pets.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:47", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a cat.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:48", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own cats?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:49", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the first name and age of students who have a dog but do not have a cat.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:50", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the first name of every student who has a dog but does not have a cat?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:51", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the type and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:52", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What type of pet is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , pet_age , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:53", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all pets that is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:54", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every pet who is over 1 year old?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:55", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the last name of the student who has a cat that is 3 years old.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:56", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the last name of the student who has a cat that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:57", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:58", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "select avg(age) from student where stuid not in (select stuid from has_pet)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:59", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many models does each manufacturer produce? List maker full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:60", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:61", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the car that is lighter than average .", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:62", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the car that is lighter than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:63", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the makers that produced some cars in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN car_names AS T3 ON T2.model = T3.MakeId WHERE T3.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:64", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car makers who produced a car in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN car_names AS T3 ON T2.model = T3.model WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:65", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the cars that were produced in the earliest ?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "{\"sql\": \"SELECT T1.Maker , T2.year FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.model = (SELECT T1.model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullName = (SELECT T1.fullName FROM car_makers AS T", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:66", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maker of the carr produced in the earliest and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t1.year FROM car_makers AS t1 JOIN car_names AS t2 ON t1.id = t2.make WHERE t2.model = 'carr' ORDER BY t1.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:67", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinct car models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN car_names AS T3 ON T2.model = T3.model WHERE T3.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:68", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the cards produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.MakeId WHERE T1.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:69", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which of the nations has the most car makers? List the country name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:70", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the nation with the most car makers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T1.CountryName ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:71", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced by each manufacturer? List the count and the maker full name.", + "gold_sql": "select count(*) , t2.fullname from model_list as t1 join car_makers as t2 on t1.maker = t2.id group by t2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:72", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models that are produced by each company and what is the id and full name of each maker?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.fullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:73", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'Amsterdam' AND model = 'Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:74", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car makers are there in france?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:75", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of makers of care in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM country AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:76", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.id = T2.countryid WHERE T2.countryname = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:77", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the car models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:78", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the 4 CYL cars?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:79", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the 8 CYL car produced on 1974 ?", + "gold_sql": "select min(weight) from cars_data where cylinders = 8 and year = 1974", + "pred_sql": "SELECT Weight FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:80", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the nations having at least one car maker? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.Id FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.MakeId = T2.Id GROUP BY T1.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:81", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all nations with at least one car maker?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.CountryId GROUP BY T1.CountryId HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:82", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the cars with more than 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:83", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of cars with over 150 hp?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:84", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which countries in europe have at least 3 car manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.Continent = \"Europe\" GROUP BY T1.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:85", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European countries with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Toyota\" GROUP BY T2.Country HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:86", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.MPG = (SELECT max(MPG) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:87", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the car wmodel that is the most fuel efficient?", + "gold_sql": "select t1.model from car_names as t1 join cars_data as t2 on t1.makeid = t2.id order by t2.mpg desc limit 1;", + "pred_sql": "SELECT cars_data.model FROM cars_data JOIN car_names ON cars_data.id = car_names.makeid ORDER BY cars_data.mpg LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:88", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower of the cars before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:89", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average horsepower for all cards produced before 1980?", + "gold_sql": "select avg(horsepower) from cars_data where year < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:90", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the cars of volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:91", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:92", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What car has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT make FROM car_names GROUP BY make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:93", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "how many cars were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:94", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many cars were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:95", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many car models were produced by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:96", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of car models created by American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:97", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 car models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:98", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all car companies with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:99", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive models are produced by General Motors or heavier than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" OR T1.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:100", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either General Motors or over 3500 lbs?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Maker = T2.Model WHERE T2.Make = 'General Motors' OR T1.Model > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:101", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "In which years cars were produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:102", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were cars produced between 3000 and 4000 pounds?", + "gold_sql": "select distinct year from cars_data where weight between 3000 and 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:103", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For volvo, how many cylinders does the car with the least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT accelerate , cylinders FROM cars_data ORDER BY cylinders ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:104", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For a volvo , how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT T1.cylinders FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE make = \"Volvo\" AND accelerate = (SELECT min(accelerate) FROM cars_data WHERE make = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:105", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "How many nations has more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:106", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the number of nations with more than 2 car makers ?", + "gold_sql": "select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:107", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 CYL cars, which model has the most horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.id = t2.makeid WHERE t1.cylinders = 4 GROUP BY t2.model ORDER BY t1.horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:108", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the 8 CYL cars or cars produced before 1980 ?", + "gold_sql": "select max(mpg) from cars_data where cylinders = 8 or year < 1980", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:109", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T1.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:110", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T1.make = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:111", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the countries which have more than 3 car makers or produce the 'fiat' ?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.id , T1.countryname FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.id GROUP BY T1.id HAVING count(*) > 3 UNION SELECT T3.id , T3.countryname FROM cars_data AS T3 JOIN car_makers AS T4 ON T3.id = T4.id JOIN countries AS T5 ON T4.country = T5.countryid WHERE T4.maker = 'FIAT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:112", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all countries that either have more than 3 car makers or produce fiats?", + "gold_sql": "select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 3 union select t1.countryid , t1.countryname from countries as t1 join car_makers as t2 on t1.countryid = t2.country join model_list as t3 on t2.id = t3.maker where t3.model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Ford\" OR T2.Maker = \"BMW\" OR T2.Maker = \"Toyota\" OR T2.Maker = \"Honda\" OR T2.Maker = \"Tesla\" OR T2.Maker = \"Mercedes-Benz\" OR T2.Maker = \"Toyota\" OR T2.Maker = \"BMW\" OR T2.Maker = \"Ford\" OR T2.Maker = \"Honda\" OR T2.Maker = \"Tesla\" OR T2.Maker = \"Mercedes-Benz\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:113", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which country does \"\"JetBlue Airways\"\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:114", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What country is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = 'Jetblue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:115", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the abbreviation of \"\"JetBlue Airways\"\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:116", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which abbreviation corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:117", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List all airline names and their abbreviations in \"\"USA\"\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:118", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the airline names and abbreviations for airlines in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:119", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:120", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE airportname = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:121", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airline is also known as UAL?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:122", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the airline called UAL.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT * FROM airlines WHERE Airline = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:123", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many airlines are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:124", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airlines in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:125", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What is the name for AKO?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:126", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of AKO.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"AK\" AND T2.Airline = \"Airline\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:127", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airport names at Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:128", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of airports in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:129", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from APG?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:130", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:131", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arrive at ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:132", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATOL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:133", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:134", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:135", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen ?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:136", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:137", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from Aberdeen and arrive at Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Ashley\" AND T1.sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:138", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\" AND T1.airportname = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:139", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline WHERE T2.airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:140", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines JOIN flights ON flights.airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:141", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Aline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:142", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'ASY' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:143", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights depart from 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abnvention = 'United Airlines' AND T1.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:144", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abreviation = \"United\" AND T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:145", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'Aberdeen' AND T1.Airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:146", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T3.Ui = T1.airline WHERE T2.city = \"Aberdeen\" AND T3.Abbreviation = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:147", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have some flight departing from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:148", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight from AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:149", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are airlines that have flights arriving at AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:150", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have a flight to AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:151", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from both APG and CVO.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.FlightNo = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.FlightNo = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:152", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departing flights from both APG and CVO ?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"APG\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:153", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find all airlines that have flights from 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'CVO' EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:154", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airlines have departures from CVO but not from APG?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T1.Abbreviation = \"CVO\" EXCEPT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.DestAirport WHERE T1.Abbreviation = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:155", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of \"\"United Airlines\"\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT DISTINCT flightno FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline WHERE T2.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:156", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which flight numbers correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT flightno FROM flights WHERE airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:157", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:158", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:159", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at APG?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:160", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:161", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights departing from Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:162", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:163", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "What are flight numbers of flights arriving at Aberdeen?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Abbeville\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:164", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight numbers of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:165", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the number of flights landing in Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:166", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:167", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of airports which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , srcairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:168", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "flight_2", + "question": "Which airports do not have departing or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:169", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort employee names from youngest to oldest.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:170", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of employees and sort from youngest to oldest", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT Name FROM employee ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:171", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which cities do more than one employee younger than 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:172", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the cities that have more than one employee under 30 year old.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:173", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each place.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT LOCATION , count(*) FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:174", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many shops are there in each place?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT LOCATION , count(*) FROM shop GROUP BY LOCATION", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:175", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the manager name and district of the shop with the most goods.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:176", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the manager name and district of the shop that sells the most merchandise?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY Number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:177", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, location and district of all shops odered by the amount of goods they sell from the most to the least.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY Number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:178", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the shops by amount of merchandise in descending order, and return the name, location and district of each shop.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:179", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores that have more than average goods.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM shop GROUP BY shop_id HAVING avg(number_products) > (SELECT avg(number_products) FROM shop))", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:180", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops have more than average merchandise? Give me the shop names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:181", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the employee who got the highest one time incentive.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:182", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which employee received the biggest incentive? Give me the employee name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:183", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the shop that is recruiting the largest number of employees?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:184", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most employees? Give me the shop name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:185", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the shops that do not recruit any employee.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:186", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops run with no employees? Find the shop names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:187", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:188", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 and more than 10000 merchandise.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:189", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers from youngest to oldest.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:190", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers from youngest to oldest?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:191", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the name of teachers who are not from Little Lever Urban District.", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Staring_Date != '2023-04-18' AND Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:192", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who do not come from Little Lever Urban District?", + "gold_sql": "select name from teacher where hometown != \"little lever urban district\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != 'Little Lever Urban District'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:193", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of teachers who are either 32 or 33 years old?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:194", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers who are either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:195", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What is the hometown of the youngest teacher?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:196", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest teacher from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:197", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show different hometown of teachers and the number of teachers from each place.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:198", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "For each place, how many teachers are from there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT T2.Staring_Date , count(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Staring_Date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:199", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the most common place that the teachers come from", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:200", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two teachers come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT Staring_Date FROM course_arrange GROUP BY Staring_Date HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:201", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the teacher who teaches math .", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course % = 5 AND T3.Course % = 10 AND T3.Course % = 15 AND T3.Course % = 20 AND T3.Course % = 25 AND T3.Course % = 30 AND T3.Course % = 35 AND T3.Course % = 40 AND T3.Course % = 45 AND T3.Course % = 50 AND T3.Course % = 55 AND T3.Course % = 60 AND T3.Course % = 65 AND T3.Course % = 70 AND T3.Course % = 75 AND T3.Course % = 80 AND T3.Course % = 85 AND T3.Course % = 90 AND T3.Course % = 95", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:202", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT name FROM teacher WHERE course_id IN (SELECT T1.course_id FROM course AS T1 JOIN course_arrange AS T2 ON T1.course_id = T2.course_id WHERE T2.grade = 3) AND T1.course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:203", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "List the names of teachers who have not been assigned to teach courses.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:204", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the teachers whose courses have not been assigned?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:205", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "How many visitors below 30 years old are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:206", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the visitors that is higher than lv 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:207", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the visitors not higher than lv 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE lv_of_membership != 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:208", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most employees?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:209", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of staff working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:210", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and staff number of Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT Open_Year , Num_of_Staff FROM museum WHERE Name = \"Plaza Museum\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:211", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more staff than the minimum of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:212", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for people who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:213", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of people who have paid the largest amount of money overall in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id WHERE T1.total_spent = (SELECT max(total_spent) FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:214", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum that has people come most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.museum_id , T2.name FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id GROUP BY T1.museum_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:215", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no person come yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum EXCEPT SELECT T1.name FROM museum AS T1 JOIN visit AS T2 ON T1.museum_id = T2.museum_id JOIN visitor AS T3 ON T2.visitor_id = T3.id WHERE T3.level_of_membership = \"Private\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:216", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the people who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id GROUP BY T1.visitor_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:217", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the lv 1 visitors?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.Total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T1.level_of_membership = 'Lv 1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:218", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first name and birth date of all players from USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:219", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and birth dates of players from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:220", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of tournament that has more than 10 matches.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:221", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 matches?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:222", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:223", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of players who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:224", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all matches who played in 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:225", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many matches were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:226", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the country code and first name of the players who won in both WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tournament_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tournament_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:227", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the first names and country codes for players who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:228", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the first name and country code of the oldest player.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:229", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the first name and country code of the oldest player?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players WHERE birth_date = (SELECT max(birth_date) FROM players)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:230", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players ordered by their age.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:231", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all players, sorted by age?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:232", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "List the first and last name of all players who are left handed in the order of age.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:233", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed players, in order of age?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:234", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the person who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T2.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:235", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the player who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:236", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = 'Australian Open' ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:237", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.winner_id = T3.player_id WHERE T3.tours = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:238", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the match that last for the longest of time.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:239", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest match?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T2.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:240", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the number of players for each nation.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:241", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many players are from each nation?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:242", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "find the code of the nation where has the greatest number of players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:243", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What is the code of the nation with the most players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:244", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the codes of nations that have more than 50 players.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:245", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the codes of nations with more than 50 players?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:246", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest victors across all matches.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:247", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest victors across all matches?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:248", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"wta\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:249", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:250", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "How many ships ended up being Captured?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:251", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the battles that led to more than 10 people died.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:252", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "What is the ship id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:253", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the battle that has lost Lettice and HMS Atalanta", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta' AND T1.result = 'lost' AND T2.latin_commander = 'Lettice'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:254", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the battles with no ships lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:255", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:256", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the descriptions for all the math?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:257", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the address in Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:258", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:259", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the last name of the students who currently live in North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM students AS T2 JOIN student_enrolment_courses AS T3 ON T2.student_id = T3.student_course_id JOIN degree_programs AS T4 ON T3.course_id = T4.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:260", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the last name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM students AS T2 JOIN student_enrolment_courses AS T3 ON T2.student_id = T3.student_course_id JOIN degree_programs AS T4 ON T3.degree_program_id = T4.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:261", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of Timmothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT T2.cell_mobile_number FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.line_3 = \"Timmothy Ward\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:262", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the mobile phone number of the student named Timmothy Ward ?", + "gold_sql": "select cell_mobile_number from students where first_name = 'timmothy' and last_name = 'ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:263", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the student register earliest? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:264", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the first name, middle name and last name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_id WHERE T2.transcript_date = (SELECT max(transcript_date) FROM Transcripts) AND T1.date_left = (SELECT min(date_left) FROM Students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:265", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first, middle, and last name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:266", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 , T1.city FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:267", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the place with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.line_1 , T2.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T2.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:268", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the semester when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.Degree_Program_id = 'Master' INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id WHERE T3.Degree_Program_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:269", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the semester that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id JOIN degree_programs AS T4 ON T4.degree_program_id = T2.degree_program_id WHERE T4.degree_summary_name = 'Masters' INTERSECT SELECT T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id JOIN degree_programs AS T4 ON T4.degree_program_id = T2.degree_program_id WHERE T4.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:270", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the first name of the students who permanently live in Haiti or have the cell phone number 09700166582.", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN students ON T1.student_id = T2.student_id WHERE T2.permanent_address_id IN (SELECT T3.permanent_address_id FROM addresses AS T3 JOIN students AS T2 ON T3.address_id = T2.current_address_id WHERE T3.country = \"Haiti\" UNION SELECT T1.cell_mobile_number FROM students WHERE cell_mobile_number = \"09700166582\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:271", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the first names of the students who live in Haiti permanently or have the cell phone number 09700166582?", + "gold_sql": "select t1.first_name from students as t1 join addresses as t2 on t1.permanent_address_id = t2.address_id where t2.country = 'haiti' or t1.cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM students WHERE cell_mobile_number = 09700166582 OR permanent_address_id = (SELECT address_id FROM addresses WHERE country = \"Haiti\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:272", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the names of all cartoons in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:273", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the cartoons sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:274", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List all cartoon Ben Jones directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:275", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all cartoons Ben Jones directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:276", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons Joseph Kuhr writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:277", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of cartoones Joseph Kuh writes?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuh\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:278", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "list all cartoon titles and their directors ordered by the time they broadcasted", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:279", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the cartoons that are ordered by the time they came out?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:280", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all cartoon Ben Jones or Brandon Vietti directs.", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = 'Ben Jones' OR directed_by = 'Brandon Vietti'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:281", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the titles of all cartoons Ben Jones or Brandon Vietti directs?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:282", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Which nation has the most of TV Channels? List the country and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM tv_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:283", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the nation with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM TV_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:284", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE Content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:285", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM tv_channel WHERE Country = \"Sky\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:286", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with \"\"Sky Radio\"\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:287", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:288", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels speak English ?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:289", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows The Rise of the Blue Beetle!? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE Content = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:290", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name of the TV Channel that shows \"\"The Rise of the Blue Beetle\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM tv_channel WHERE content = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:291", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the title of all Cartoons showed on TV Channel with \"\"Sky Radio\"\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE series_name = \"Sky Radio\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:292", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the title of all the cartools that are on the TV Channel with Sky Radio?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT title FROM cartoon WHERE channel = (SELECT id FROM tv_channel WHERE content = 'Sky Radio')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:293", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the air date of \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Air_Date FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.channel WHERE T1.title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:294", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "When did A Love of a Lifetime air?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:295", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with A Love of a Lifetime?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:296", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the weekly rank for the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:297", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel with \"\"\"\"A Love of a Lifetime\"\"\"\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.channel FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:298", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of the series that has the \"\"\"\"A Love of a Lifetime\"\"\"\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT series_name FROM TV_channel WHERE Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:299", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with \"\"\"\"Sky Radio\"\"\"\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.content = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:300", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series called Sky Radio?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:301", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of cartoons by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:302", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "How many cartoons did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:303", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the production code and channel of the most recently broadcasted cartoon.", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:304", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction code and channel of the most recent cartoon?", + "gold_sql": "select production_code , channel from cartoon order by original_air_date desc limit 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:305", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and series name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , Series_name FROM TV_Channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:306", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the series for the TV Channel that supports HDTV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HDTV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:307", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some cartoon Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:308", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that have cartoons on TV that Todd Casey writes?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel JOIN tv_series AS T3 ON T2.channel = T3.id WHERE T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:309", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any cartoon Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_channel EXCEPT SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:310", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the countries that are not playing cartoons Todd Casey writes?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.channel = t2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:311", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "Find the series name and country of the tv channel that is playing some cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" AND t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:312", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the series name and country of all TV channels that are playing cartoons Ben Jones and Michael Chang directs?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" AND t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:313", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:314", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and country of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:315", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the nations where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:316", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any cartoon Ben Jones directs.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:317", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any cartoons Ben Jones directs?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:318", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any cartoon Ben Jones directs.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T1.Package_Option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:319", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any cartoons Ben Jones directs?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT Channel FROM cartoon) AND Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:320", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "List the mony made by each poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Money_Rank , Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:321", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest poker player?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:322", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the tallest poker player.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:323", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What is the average earnings of poker players taller than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:324", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Give average earnings of poker players who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.people_id = T2.people_id WHERE T2.height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:325", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are different nationalities of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:326", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:327", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people from.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:328", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people who is not from Russia.", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:329", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:330", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:331", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:332", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "What are the create dates, states, and phone numbers of the votes that were for 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T1.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:333", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for 'Tabatha Gehling' and 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.state FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T1.contestant_number FROM votes AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling') INTERSECT SELECT T1.state FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T1.contestant_number FROM votes AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:334", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the countries that founded after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:335", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:336", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many republic countries are there?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE region = \"República\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:337", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many countries are republic?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT country) FROM city WHERE region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:338", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of the countries in the Caribbean ?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:339", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How much surface area do the countires in the Carribean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN country AS T2 ON T1.Continent = T2.Continent WHERE T2.Name = \"Carribean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:340", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"Antarctica\" INTERSECT SELECT continent FROM country WHERE code = \"South America\" INTERSECT SELECT continent FROM country WHERE code = \"North America\" INTERSECT SELECT continent FROM country WHERE code = \"Europe\" INTERSECT SELECT continent FROM country WHERE code = \"Africa\" INTERSECT SELECT continent FROM country WHERE code = \"Asia\" INTERSECT SELECT continent FROM country WHERE code = \"Australia\" INTERSECT SELECT continent FROM country WHERE code = \"North Korea\" INTERSECT SELECT continent FROM country WHERE code = \"Southeast Asia\" INTERSECT SELECT continent FROM country WHERE code = \"Southeast Europe\" INTERSECT SELECT continent FROM country WHERE code = \"South America\" INTERSECT SELECT continent FROM country WHERE code = \"South Asia\" INTERSECT SELECT continent FROM country WHERE code = \"Pacific\" INTERSECT SELECT continent FROM country WHERE code = \"Antarctica\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:341", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the continent which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:342", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which region is Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN country AS T2 ON T1.Capital = T2.Capital WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:343", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T1.Capital = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:344", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:345", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:346", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population and life expectancies in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.Population , T1.LifeExpectancy FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:347", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil’s population and life expectancies.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:348", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the region and population of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:349", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its population?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T2.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:350", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average expected life expectancy for countries in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:351", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average life expectancy in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:352", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the name of country that has the shortest life expectancy in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:353", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the country in Asia with the lowest life expectancy.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:354", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(T1.Population) , max(T1.GNP) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:355", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , sum(population) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:356", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average life expectancy in African countries that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Republic\" AND Name IN (SELECT T1.Name FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T2.Region = \"Country\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:357", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the average life expectancy for countries in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:358", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total surface area of Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:359", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total surface area covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:360", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE name = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:361", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population of Gelderland ?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE Name = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:362", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total population in all US territory nations?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE continent = 'North America' OR continent = 'South America' OR continent = 'Asia' OR continent = 'Oceania'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:363", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total population of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE Region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:364", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:365", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many different forms of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:366", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country Code = \"ARUD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:367", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode = (SELECT name FROM city WHERE countrycode = 'Aruba' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:368", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Afghanistan' AND T1.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:369", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Afghanistan' AND T1.isofficial = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:370", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:371", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the nation that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:372", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:373", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:374", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:375", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:376", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations use both English and French officially?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 'Yes' AND T2.Language = \"French\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 'Yes' AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:377", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries officially use English and French", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:378", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:379", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code2 WHERE t1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:380", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:381", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Rname FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Dutch\" OR T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:382", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries where either English or Dutch is officially spoken ?", + "gold_sql": "select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"english\" and isofficial = \"t\" union select t1.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode where t2.language = \"dutch\" and isofficial = \"t\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:383", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on Asian ?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name In ('Asia', 'Indonesia') GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:384", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:385", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code EXCEPT SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:386", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single republic country?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT L1.Language FROM countrylanguage AS L1 JOIN country AS L2 ON L1.CountryCode = L2.Code JOIN city AS L3 ON L2.Code = L3.CountryCode WHERE L3.District = \"R\" GROUP BY L1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:387", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the city with the most people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode JOIN country AS T3 ON T2.language = T3.name WHERE T3.name = 'English' GROUP BY T1.name ORDER BY sum(T1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:388", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.CountryCode WHERE T2.Language = \"English\" GROUP BY T2.name ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:389", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, population, and life expectancy of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code WHERE T1.name = 'Asia' ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:390", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is average life expectancy in the countries where English is not used officially ?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:391", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the mean life expectancy of countries in which English is not officially spoken .", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:392", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:393", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many people live in countries that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:394", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country lead by Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:395", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose chief of state is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:396", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the countries that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name < '1930' AND T2.isofficial = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:397", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "For the countries founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT isofficial) FROM countrylanguage WHERE countrycode <= \"US\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:398", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the countries that have greater surface area than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:399", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which countries larger than that of any country in Europe by land?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:400", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the African countries that have less people than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:401", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which African countries have fewer people than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' INTERSECT SELECT name FROM country WHERE population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:402", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which Asian countries have more people than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT max(name) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:403", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian countries have more people than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' GROUP BY countrycode HAVING max(population) > (SELECT min(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:404", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes for countries that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:405", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the country codes for countries that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:406", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the country codes of countries where people speak other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:407", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the country codes for countries in which people does not speak English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:408", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the countries that do not speak English and are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\") AND governmentform != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:409", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of non republic countries that do not speak Englishs.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT CountryCode FROM country WHERE Countrycode != \"Bangladesh\" AND Isofficial != 1 UNION SELECT CountryCode FROM countrylanguage WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:410", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Which cities are in European countries where English is not spoken officially?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.CountryCode WHERE T3.IsOfficial = 0 AND T2.Name = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:411", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique cities are in Asian countries where Chinese is the official ?", + "gold_sql": "select distinct t3.name from country as t1 join countrylanguage as t2 on t1.code = t2.countrycode join city as t3 on t1.code = t3.countrycode where t2.isofficial = 't' and t2.language = 'chinese' and t1.continent = \"asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.name = 'Asia' AND T3.Language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:412", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of cities that are in Asia and for which Chinese is used officially .", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T3.IsOfficial = 1 AND T2.name = 'Asia' AND T3.Language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:413", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the name, independence year, and surface area of the country with the least number of nationalities?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , surfacearea FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:414", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of independence, and surface area of the country that has the fewest people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , surfacearea FROM country ORDER BY population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:415", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the population, name and leader of the largest country by land?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.population , t1.name , t1.HeadOfState FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code WHERE t1.region = \"Surface Area\" ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:416", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Find the number of cities in each district who have more people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:417", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "How many cities in each district have more number of people than average?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:418", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names and surface areas of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:419", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are names of top 3 countries with most people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:420", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:421", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the nations with the 3 lowest number of citizens?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:422", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 countries with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:423", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "how many countries are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:424", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:425", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries that are in Europe and have 80000 people?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:426", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that are in Europe and have 80000 people.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:427", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total population and average area of countries in North America who is bigger than 3000 square miles", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(population) , avg(surfacearea) FROM country WHERE continent = 'North America' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:428", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Give the total population and average corresponding to countries in Noth America that is bigger than 3000 square miles.", + "gold_sql": "select sum(population) , avg(surfacearea) from country where continent = \"north america\" and surfacearea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.name = \"North America\" AND t1.SurfaceArea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:429", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the cities who have more than 160000 people and less than 900000 people?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population > 160000 AND population < 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:430", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the names of cities that have between 160000 and 900000 people.", + "gold_sql": "select name from city where population between 160000 and 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:431", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by the largest percentage of people in each nation?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.% , T1.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY SUM(T2.% ) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:432", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of the different nations, and what are the languages spoken by the greatest percentage of people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:433", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(Percentage) FROM countrylanguage WHERE Language = \"Spanish\" ORDER BY sum(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:434", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Count the number of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:435", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of countries where Spanish is spoken by the largest percentage of people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:436", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of countries for which Spanish is predominantly spoken .", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:437", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "List the names of conductors from youngest to oldest.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:438", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors, ordered by how old they are?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:439", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of conductors who are not from \"\"USA\"\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:440", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of non USA conductors.", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:441", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "What are the record companies of orchestras in descending order of time in which they started?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:442", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Return the record companies of orchestras, sorted ascending by the time they have existed.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:443", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of orchestras recorded in \"\"\"\"CD\"\"\"\" or \"\"\"\"DVD\"\"\"\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE orchestra = \"CD\" OR orchestra = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:444", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:445", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:446", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all high schoolers in 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:447", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all high schoolers in 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:448", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:449", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:450", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are there in 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:451", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of high schoolers in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:452", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the number of high schoolers for each year.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:453", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many high schoolers are in each year?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:454", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Which year has the most high schoolers?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM highschooler GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:455", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 1019", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:456", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 1015", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:457", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many friends does Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend WHERE student_id = (SELECT id FROM highschooler WHERE name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:458", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 598355665", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:459", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "How many likes does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:460", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Return the number of likes Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.ID WHERE T1.student_id = 10115", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:461", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:462", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:463", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:464", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:465", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals live in Indiana or have done treatment on more than 2 treatments? List his or her id, last name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT cell_number , last_name , home_phone FROM Professionals WHERE STATE = \"IND\" UNION SELECT T1.cell_number , T1.last_name , T1.home_phone FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:466", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the professionals who live in Indiana or have performed more than two treatments.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2 INTERSECT SELECT T1.professional_id , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.state = \"Indiana\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:467", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the owner spent more than 1000 for treatment?", + "gold_sql": "select name from dogs where dog_id not in ( select dog_id from treatments group by dog_id having sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T3.owner_id = T2.owner_id WHERE T3.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:468", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which person has the most dogs? List the id, first name and last name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.owner_id FROM Dogs AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:469", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the id, first name and last name of the person who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:470", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which doctors have done at least two treatments? List theid, role, and first name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.treatment_id , T2.role_code , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.role_code HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:471", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and first name of the people who have performed two or more treatments?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.treatment_id , T1.role_code , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.role_code HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:472", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the description of the treatment type that is the cheapest overall?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type_code ORDER BY cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:473", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the description of the treatment type that is least expensive.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.treatment_type_code = T2.charge_type_code ORDER BY cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:474", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who has paid the largest amount of money in total for their dogs? Show the id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:475", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and zip code of the person who spent the most money in total for his or her dogs.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:476", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and last name of the professionals who have done treatment cheaper than average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING avg(cost_of_treatment) < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:477", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which professionals have operated a treatment that is less expansive than the average? Give me theor first names and last names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id JOIN treatments AS T3 ON T3.professional_id = T1.professional_id WHERE T2.treatment_type_code = \"Less Expansive\" AND T3.cost_of_treatment != (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:478", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the owner's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:479", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names of owners living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:480", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the last name of the owner owning the youngest dog.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:481", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest dog? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:482", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the professionals who live in Hawaii or Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:483", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the professionals living in either Hawaii or Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:484", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How many dogs younger than average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:485", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of dogs that are younger than the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:486", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "How much is the most recent treatment?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:487", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the price of the most recently performed treatment.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:488", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "List the dog name, age and weight of the dogs who have been abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:489", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the dog name, age and weight of the dogs that were abandoned?", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:490", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers in ascending order of wealth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:491", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of singers ordered by ascending wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:492", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "List the name of singers whose is not French.", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:493", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who are not French?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:494", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the name of singers who were born either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:495", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the names of the singers who born in either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:496", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the name of the singer with the largest wealth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:497", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities of singers and the number of singers of each.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:498", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "how many singers are from each country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship;", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:499", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Please show the most common nationality of singers.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:500", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What is the msot common country for singer?", + "gold_sql": "select citizenship from singer group by citizenship order by count(*) desc limit 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:501", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show different nationalities and the maximum net worth of singers of country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_wealth_millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:502", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(networth) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:503", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of singers that have songs sell more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:504", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the singers that have sold than 300000 copies?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:505", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by singers born before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:506", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "singer", + "question": "What are the citizenships that are shared by singers born before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_realistic:test:507", + "benchmark": "spider_realistic", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT T1.property_name FROM properties AS T1 JOIN ref_property_ttypes AS T2 ON T1.property_type_code = T2.property_type_code WHERE T2.property_type_description = 'house' UNION SELECT T1.property_name FROM properties AS T1 JOIN ref_property_ttypes AS T2 ON T1.property_type_code = T2.property_type_code WHERE T2.property_type_description = 'apartment' AND T1.room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..9865c8a898237eca0284b4aa5e241c99ca8c6186 --- /dev/null +++ b/infer/qwen/spider_syn/amid_train_0.6b_4b_spider_ab_pr_0.5_0.5_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer WHERE is_vocalist = 'yes' ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , COUNT(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , state FROM musician GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , highest FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t2.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.year FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T2.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.concert_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.name , T2.theme , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_ID = T3.concert_ID GROUP BY T3.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_title LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_title LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.position FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.position FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = t2.stadium_id ORDER BY t2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT max(weight) FROM Pets WHERE pettype = \"Puppy\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Sex = \"F\" AND T1.Fname = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = \"F\" AND T2.pets = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT name) FROM animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kittens\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppies\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Major , T1.Age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID NOT IN (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID WHERE T2.pettype = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Pug\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"dog\") EXCEPT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"cat\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(age) , max(age) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pet_age = 3 AND T3.pettype = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pet_age = 3 AND T3.pet_type = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.Continent , count(*) , T1.ContId FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT t1.continent , count(*) , t2.contid FROM continents AS t1 JOIN countries AS t2 ON t1.contid = t2.contid GROUP BY t2.contid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY max(horsepower) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model_id WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.Year FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T1.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.model = T2.model WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , count(*) FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.MakeId = T2.Id GROUP BY T1.MakeId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.StateName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.countryid GROUP BY t1.maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId WHERE T1.FullName = 'amc hornet sportabout (sw)'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'Tesla' AND model = 'Roadster'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName LIKE '%French%';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'Ford' AND T1.country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'Toyota' AND T1.country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT Weight FROM cars_data WHERE Year = 1974 AND Cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT T1.Maker , T1.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T2.Maker , T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker != \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN country AS T2 ON T1.country = T2.CountryId GROUP BY T1.id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.Continent FROM continents AS T1 JOIN car_makers AS T2 ON T1.Continent = T2.Country WHERE T2.Maker != \"Toyota\" GROUP BY T1.Continent HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker WHERE T2.cylinders = 3 GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T2.Maker FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY sum(mpg) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , Cylinders FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Make = (SELECT T2.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model GROUP BY T2.Model ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model GROUP BY T1.Model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T1.FullName = \"General Motors\" OR T2.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE Weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT horsepower FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(cylinders) FROM cars_data WHERE make = 'volvo' ORDER BY accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.Cylinders = 4 GROUP BY T1.Model ORDER BY MAX(Horsepower) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullName FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.makeid = T2.id GROUP BY T1.makeid HAVING horsepower > (SELECT min(horsepower) FROM cars_data) EXCEPT SELECT makeid , fullName FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.makeid = T2.id WHERE cylinders > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE horsepower > 0 AND cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.weight < 3500 EXCEPT SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.weight >= 3500 AND T1.Maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T2.CountryName HAVING count(*) = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "{\"sql\": \"SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker != 'Toyota'}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T2.Maker FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model GROUP BY T2.Maker HAVING count(*) >= 2 INTERSECT SELECT T1.id , T2.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T2.Maker HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.CountryName FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model WHERE T3.Model = 'fiat' GROUP BY T1.CountryName HAVING count(*) > 3 UNION SELECT T1.Id , T1.CountryName FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model WHERE T3.Maker = 'carmakers' GROUP BY T1.CountryName HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Id HAVING count(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = ' Fiat '", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM states AS T1 JOIN airlines AS T2 ON T1.airlinecode = T2.abbreviation WHERE T2.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airline WHERE T2.FlightNo = 1356", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , airportcode FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirwayName , T1.ShortenedWord FROM airports AS T1 JOIN airlines AS T2 ON T1.AirportCode = T2.AirportCode WHERE T2.Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(T1.Airway) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T1.DestAirport != 'AA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T2.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport JOIN airlines AS T3 ON T3.UID = T2.Airline WHERE T3.Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = 'Alton'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT town , country FROM airports WHERE AirportName = 'Alton'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Terminal ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"AT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = 'Aberdeen' AND T1.DestAirport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Ashley\" AND T1.DestAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Aline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Aline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT T1.airline , count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.abbr = 'United Airlines' AND T2.destairport = 'ASY' GROUP BY T1.airline HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ASY Airport' AND T1.Airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid JOIN airports AS T3 ON T3.airportcode = T1.sourceairport WHERE T3.airportname = 'AHD' AND T2.Abbreviation = 'UAF'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\" AND T1.Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen' AND T1.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\" AND T1.airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportName ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportName ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.destairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T2.AirportCode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Airway , T2.State FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode GROUP BY T1.SourceAirport ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.AirportCode FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.FlightNo = (SELECT min(FlightNo) FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.City = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airlines AS T3 ON T3.uid = T2.airline WHERE T3.Abbreviation = 'APG' INTERSECT SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airlines AS T3 ON T3.uid = T3.uid WHERE T3.Abbreviation = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T3.airportcode = T2.destairport WHERE T1.countryabbreviation = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T3.airportcode = T2.destairport WHERE T1.countryabbreviation = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport EXCEPT SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.SourceAirport IN (SELECT airportcode FROM airports WHERE countryabbreviation = 'CVO') EXCEPT SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline WHERE T2.DestAirport IN (SELECT airportcode FROM airports WHERE countryabbreviation = 'APG')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode HAVING sum(T2.flightno) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.Airline , T1.FLIGHTNO FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.SourceAirport WHERE T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.Airline , T1.FlightNo FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.SourceAirport WHERE T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.City = \"Aberdeen\" OR T1.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , district FROM shop GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T2.director_name , T2.distRICT FROM shop AS T1 JOIN employee AS T2 ON T1.manager_name = T2.employee_id GROUP BY T1.manager_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM shop GROUP BY name , district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , LOCATION FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T2.is_full_time = 'Y' ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T2.bonus = (SELECT max(bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT manager_name FROM hiring GROUP BY manager_name HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T2.name , count(*) FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T1.name FROM shop AS T1 JOIN hiring AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T1.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID WHERE T1.year_awarded = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID WHERE T1.year_awarded >= 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents WHERE document_type = \"Paper\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.paragraph_id , T3.paragraph_text , T2.document_description FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id JOIN templates AS T3 ON T1.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text , T1.Other_details FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_name , T1.layout_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.paper_id , t2.layout_id , t3.document_description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id JOIN Templates AS t3 ON t1.template_id = t3.template_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t3.document_id , t2.layout_id , t1.template_details FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id JOIN templates AS t3 ON t1.template_id = t3.template_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T1.Other_Details = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T1.Other_details = 'PPT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE Template_ID IN (SELECT Template_ID FROM Templates WHERE template_type_code = \"PPT\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM (SELECT T1.layout_id , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.layout_id) AS T;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , layout_id FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT document_id , template_type_description FROM documents JOIN templates ON documents.document_id = templates.document_id GROUP BY document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Documents AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT T1.template_id FROM documents AS T1 JOIN paragraphs AS T2 ON T1.paragraph_id = T2.paragraph_id WHERE T1.template_id IN (SELECT T3.template_id FROM Documents AS T3 JOIN paragraphs AS T4 ON T3.paragraph_id = T4.paragraph_id WHERE T4.paragraph_text = \"textfile\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM layouts EXCEPT SELECT document_id FROM papers", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.template_id , T2.version_number , T3.template_type_description FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code JOIN Paragraphs AS T3 ON T1.paragraph_id = T3.paragraph_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT template_type_description FROM ref_template_types UNION SELECT DISTINCT t1.template_type_description FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT template_type_description FROM ref_template_types", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT T1.paragraph_id FROM documents AS T1 JOIN paragraphs AS T2 ON T1.paragraph_id = T2.paragraph_id WHERE T1.document_id IN (SELECT T3.paragraph_id FROM documents AS T3 JOIN Templates AS T4 ON T3.template_id = T4.template_id WHERE T4.template_type_code = \"PP\" OR T4.template_type_code = \"PPT\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T1.edition_number , T2.layout_type FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.date_effective_from > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T1.edition_number , T2.layout_type_name FROM Templates AS T1 JOIN (SELECT T2.layout_type_name FROM Paragraphs AS T2 JOIN Documents AS T3 ON T2.document_id = T3.document_id WHERE T3.version_number = 1) AS T1 GROUP BY T1.edition_number HAVING T1.edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT layout_type , count(*) FROM Ref_Template_Types GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types GROUP BY template_type_description HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT count(*) , template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_description HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_details LIKE \"%Data base%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id WHERE t1.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.document_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT t3.document_name FROM documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id JOIN paragraphs AS t3 ON t1.paragraph_id = t3.paragraph_id WHERE t2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.template_type_description , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT layout_type , count(*) FROM Documents GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT layout_type FROM Documents GROUP BY layout_type ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM documents AS t1 JOIN paragraphs AS t2 ON t1.paragraph_id = t2.paragraph_id GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types EXCEPT SELECT DISTINCT t2.template_type_description FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id WHERE t2.template_type_code = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types EXCEPT SELECT DISTINCT t2.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN Documents AS t3 ON t2.document_id = t3.document_id WHERE t3.Other_Details = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.layout_type_name , T2.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.template_type_description , T2.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT T1.layout_type_description , T2.layout_type_name FROM Ref_Template_Types AS T1 JOIN Template_Type_Code AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.document_name = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.template_type_code = T2.template_type_code JOIN Paragraphs AS T3 ON T2.document_id = T3.document_id WHERE T3.paragraph_text = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM Ref_Templates WHERE template_type_description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE '%Presentation%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.Other_Details = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T2.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T2.paragraph_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Welcome to NY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT paragraph_text FROM paragraphs WHERE document_id IN (SELECT id FROM documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT count(*) , T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT count(*) , T1.template_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T2.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Paragraph_id , T1.Paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.Document_id = T2.Document_id GROUP BY T1.Paragraph_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.Paragraph_ID FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.Document_ID = T2.Document_ID WHERE T1.paragraph_text = 'Brazil' INTERSECT SELECT T1.Paragraph_ID FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.Document_ID = T2.Document_ID WHERE T1.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T3.Name , T2.Course_ID FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T3.curriclure FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T3.Name , T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1 Teacher_ID = T2 Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T3.Name , T2.Course_ID FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT name FROM teacher WHERE course = 'math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T3.Name , COUNT(*) FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID GROUP BY T3.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Technician_ID = T2.Technician_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID GROUP BY T3.Name HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE level_of_membership > 4 ORDER BY level_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE level_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_of_membership FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id JOIN visitor AS T3 ON T1.visitor_id = T3.id WHERE T1.total_spent = (SELECT max(total_spent) FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT T2.total_spent FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_ID WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year < 2011 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year > 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN ( SELECT visitor_id FROM visit WHERE museum_id > 2010 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_name = \"Tournament\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches ORDER BY loser_rank LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_name WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_name WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , STATE_abbreviation FROM players WHERE birth_date = (SELECT max(birth_date) FROM players)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'yes' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T2.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.rankings_date FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T3.rankings_date ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN tournaments AS T3 ON T1.tourney_id = T3.tourney_id WHERE T3.tourney_name = 'Australian Open' ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.loser_name , T2.name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.loser_name ORDER BY sum(T1.minutes) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , avg(T2.rank) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT ranking_points , T1.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.ranking_points) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , T1.state_code FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.state_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.state , COUNT(*) FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , COUNT(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking_points , COUNT(*) FROM rankings GROUP BY ranking_points", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.ranking FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year , T1.year , T1.year LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.ranking FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.round , T2.ranking_date LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = 'left' INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = 'right'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand_type FROM players GROUP BY hand_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(killed) , min(killed) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T2.id , T1.casued_by_ship_id FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T1.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.id , t1.name FROM ship AS t1 JOIN death AS t2 ON t1.id = t2.caused_by_ship_id GROUP BY t1.id ORDER BY sum(t2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander < 'Kaloyan' AND latin_commander > 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE result = 'win' EXCEPT SELECT count(*) FROM ship WHERE tonnage = 225", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.id , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.id , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE LOCATION != 'English Channel'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM addresses WHERE line_1 = \"line 1\" AND line_2 = \"line 2\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM COURSES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.department_id FROM departments AS T1 JOIN degree_programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.division_id , T2.division_name FROM divisions AS T1 JOIN degree_programs AS T2 ON T1.division_id = T2.division_id GROUP BY T1.division_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_program_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments WHERE department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments WHERE department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.section_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.section_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T3.student_id = T2.student_id GROUP BY T3.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.semester_name , T1.student_id FROM Student_Enrolment AS T1 JOIN Semesters AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"2\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Undergrad' INTERSECT SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.department_name = 'Bachelor\\'s Degree Program'\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT degree_program_id FROM student_enrolment GROUP BY degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.degree_program_id , T2.degree_summary_name FROM Student_Enrolment AS T1 JOIN Degree_Programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T2.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Degree_Programs AS T1 JOIN Students AS T2 ON T1.degree_program_id = T2.student_enrolment_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id , count(*) FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id EXCEPT SELECT T3.semester_name FROM semesters AS T3 JOIN student_enrolment AS T4 ON T3.semester_id = T4.semester_id JOIN students AS T5 ON T5.student_id = T4.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.student_id NOT IN (SELECT T3.student_id FROM student_enrolment AS T3 GROUP BY T3.student_id HAVING count(*) > 100)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id JOIN sections AS T3 ON T2.section_id = T3.section_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_course_id JOIN courses AS T3 ON T2.course_id = T3.course_id JOIN degree_programs AS T4 ON T2.degree_program_id = T4.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN students AS T3 ON T1.student_id = T3.student_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.student_id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.transcript_id = T2.transcript_id JOIN Student_Enrolment AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT date_first_registered FROM students ORDER BY first_name , middle_name , last_name LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Graduate' ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name , last_name FROM Students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN students ON T1.student_id = T2.student_id WHERE T1.permanent_address_id != T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM Transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , other_student_details FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , other_details FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_left) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_first_registered) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.course_id FROM Student_Enrolment_Courses AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(count(*) ) , T1.course_id FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_course_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Student_Enrolment AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = \"Master\" INTERSECT SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id JOIN Degree_Programs AS T4 ON T4.degree_program_id = T2.degree_program_id WHERE T4.degree_summary_name = 'Masters' INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T3.student_id = T2.student_id JOIN Degree_Programs AS T4 ON T4.degree_program_id = T4.degree_program_id WHERE T4.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.address_id) FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T2.department_name FROM students AS T1 JOIN departments AS T2 ON T1.current_address_id = T2.department_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM students ORDER BY first_name , last_name;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM Sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.country = 'Haiti' UNION SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.country = 'United States' AND T2.cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id IN (SELECT permanent_address_id FROM addresses WHERE country = 'Haiti') UNION SELECT first_name , last_name FROM students WHERE cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM tv_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM tv_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , count(*) FROM TV_channel GROUP BY Language ORDER BY count(Language) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM tv_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.Channel , T2.series_name FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.series_name FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN TV_Channel AS T2 ON T1.id = T2.Channel WHERE T2.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.episode , T1.rating FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.channel = T2.channel ORDER BY rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Episode FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.id = T2.episode WHERE T1.Title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.episode = T2.episode WHERE T2.title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Channel FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.episode WHERE T2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.series_name FROM tv_channel AS T1 JOIN tv_series AS T2 ON T1.id = T2.channel WHERE T2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.content = \"animation\" AND T1.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT title FROM cartoon EXCEPT SELECT DISTINCT written_by FROM cartoon AS T1 JOIN Cartoon AS T2 ON T1.directed_by = T2.directed_by WHERE T1.written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.channel FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Ben Jones' INTERSECT SELECT t1.series_name , t1.channel FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.id WHERE t2.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = 'Ben Jones' INTERSECT SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T1.Package_Option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T1.Package_Option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM (SELECT T1.people_id FROM people AS T1 JOIN poker_player AS T2 ON T1.people_id = T2.people_id WHERE T2.Final_Table_Made = \"Best_Finish\" AND T2.Money_Rank = \"Earnings\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM (SELECT T1.People_ID FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Final_Table_Made = \"Best_Finish\" AND T1.Nationality = \"Chinese\" AND T2.Earnings > 100000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM people WHERE Nationality = \"Chinese\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM people WHERE Nationality = \"Chinese\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT money_rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(final_table_made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Finish = \"Best\" AND T1.Nationality = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Nationality = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 3000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings = (SELECT min(Earnings) FROM poker_player)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.people_id = T2.people_id WHERE T2.height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.people_id = T2.people_id WHERE T2.height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Yes\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Car Game\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS EXCEPT SELECT contestant_name FROM CONTESTANTS WHERE contestant_name = 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT state , created FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T2contestant_name , T1contestant_number FROM votes AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1contestant_number ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.area_code , T1.state FROM AREA_CODE_STATE AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.set_up_date , T2.state , T1.phone_number FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T1.state = 'GA' INTERSECT SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = (SELECT T2.contestant_number FROM CONTESTANTS WHERE T2.contestant_number = 'Tabatha Gehling' ))))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyyear > 1950 ORDER BY name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT Governmentform) FROM country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE governmentform = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t1.SurfaceArea) FROM country AS t1 JOIN country AS t2 ON t1.Continent = \"Caribbean\" AND t2.Region = \"North Atlantic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE name = 'Continental' AND continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT t1.Continent FROM country AS t1 JOIN country AS t2 ON t1.Continent = t2.Continent WHERE t1.Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Capital == T2.Population WHERE T2.Name == \"Kabul\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Capital == T2.District WHERE T2.Name == \"Kabul\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.Countrycode WHERE T1.Name = \"Aruba\" GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LIFEExpectancy FROM country WHERE Name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT region , population FROM country WHERE name = 'Angola'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT t1.region , count(*) FROM country AS t1 JOIN city AS t2 ON t1.countrycode = t2.countrycode WHERE t2.name = \"Angola\" GROUP BY t1.region", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE name = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND lifeexpectancy = (SELECT min(lifeexpectancy) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Continent = \"Asia\" ORDER BY T2.LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(tp.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.countrycode WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T1.Continent = \"Africa\" AND T2.Region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "{\"sql\": \"SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T1.Continent = \\\"Africa\\\" AND T2.Region = \\\"republic\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE name = 'Asia' OR name = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE continent = 'North America' OR governmentform = 'Federal'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE continent = 'North America' OR region = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE country = (SELECT code FROM country WHERE name = 'Aruba' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = 'AFG' AND isofficial = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = \"Y\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.State FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode JOIN city AS T3 ON T2.Capital = T3.Code GROUP BY T1.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"English\" AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = T2.Language WHERE T2.Name = 'English' INTERSECT SELECT T1.Name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = T2.Language WHERE T2.Name = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code2 WHERE t1.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = T2.IsOfficial WHERE T1.Language = \"English\" UNION SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = T2.IsOfficial WHERE T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T2.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = 'Republic' GROUP BY T1.Language COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.GovernmentForm = \"Republic\" GROUP BY T1.Language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" GROUP BY T1.name ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.capital = t2.countrycode WHERE t2.Language = \"English\" GROUP BY t1.name ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.Population , T2.lifeexpectancy FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Continent = \"Asia\" ORDER BY T1.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.population , T1.lifeexpectancy FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia' ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 1 AND T1.name = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.IsOfficial = 1 AND T2.Language = \"English\" AND T1.name = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(IsOfficial) FROM countrylanguage WHERE IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = \"Africa\" AND population < (SELECT max(population) FROM country AS T1 JOIN country AS T2 ON T1.Continent = \"Asia\" WHERE T2.code = T1.code)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = \"Africa\" INTERSECT SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = \"Asia\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'Asia' AND population > (SELECT max(population) FROM city WHERE countrycode = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE continent = \"Africa\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.NationCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.State FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.Nationabbrev FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code EXCEPT SELECT T1.Nationabbrev FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.nationabbrev FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode JOIN country AS T3 ON T2.Language = T3.Language WHERE T3.Name = 'India' AND T2.IsOfficial = 1 AND T1.Name != 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" EXCEPT SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 0 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" EXCEPT SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" AND T2.IsOfficial = 1 INTERSECT SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IsOfficial = 1 AND T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T2.Continent = \"Asia\" AND T3.IsOfficial = 1 AND T3.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indepyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT capital , headofstate FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.population , t1.capital FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code GROUP BY t1.code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.code HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT T1.GovernmentForm , COUNT(*) FROM country AS T1 JOIN city AS T2 ON T1.Capital = T2.District WHERE T1.lifeexpectancy > 72 GROUP BY T1.GovernmentForm", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT DISTINCT governmentform , sum(population) FROM country WHERE lifeexpectancy > 72 GROUP BY governmentform", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) , continent FROM country GROUP BY continent HAVING avg(lifeexpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT T1.Continent , sum(T2.Population) , avg(T2.lifeexpectancy) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code WHERE T1.Continent != \"North Atlantic\" GROUP BY T1.Continent HAVING avg(T2.lifeexpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , area FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT Name , Region FROM country ORDER BY Name , REGION DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.Code2 = T2.CountryCode WHERE T1.Continent = \"Europe\" AND T2.Population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'USA' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.SurfaceArea) FROM city AS t1 JOIN country AS t2 ON t1.CountryCode = t2.Code WHERE t2.Continent = \"North America\" AND t2.SurfaceArea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.population > 3000 GROUP BY t2.code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population >= 160000 AND population <= 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T1.CountryCode , T2.District FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(t1.percentage) , t2.name FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t1.Language = \"Spanish\" GROUP BY t2.name ORDER BY sum(t1.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.State FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_OF_WORK DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY Year_of_Work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE age = (SELECT max(age) FROM conductor)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id JOIN performance AS T3 ON T2.performance_id = T3.performance_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM conductor AS t1 JOIN orchestra AS t2 ON t1.conductor_id = t2.conductor_id GROUP BY t1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , count(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.Conductor_ID FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT T1.Record_company , COUNT(*) FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T1.Record_company ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT Major_record_format FROM orchestra GROUP BY Major_record_format ORDER BY COUNT(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra != \"Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra != (SELECT T1.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1 Orchestra_ID = T2 Orchestra_ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT T1.Share FROM performance AS T1 JOIN orchestra AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T2.Year_of_Founded < 2003 INTERSECT SELECT T1.Share FROM performance AS T1 JOIN orchestra AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T2.Year_of_Founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1 Orchestra_ID = T2 Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = \"Kyle\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT T1.id , T2.friend_id FROM friends AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.id FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 1011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 10101", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM student WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE student_id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE student_id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT T1.id FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id WHERE T3.student_id IN (SELECT T1.id FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id GROUP BY T3.student_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM likes INTERSECT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T3.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id WHERE T3.friend_id IN (SELECT T4.student_id FROM highschooler AS T4)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T2.name , count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2 INTERSECT SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = \"Kyle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friends)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT grade FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = \"guardian\" INTERSECT SELECT state FROM Professionals WHERE role_code = \"veterinary\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = \"guardian\" INTERSECT SELECT state FROM Professionals WHERE role_code = \"veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.charge_type = \"Medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.treatment_type_code = \"health\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name , T2.cell_number FROM Professionals AS T1 JOIN Owners AS T2 ON T1.cell_number = T2.cell_number WHERE T2.state = 'indiana' OR T1.role_code = 'medical' GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Indiana\" UNION SELECT T3.owner_id , T3.last_name , T3.cell_number FROM Professionals AS T3 JOIN Owners AS T2 ON T3.owner_id = T2.owner_id WHERE T2.state = \"Indiana\" OR T3.cell_number >= 2000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000 );", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN charges AS T3 ON T2.treatment_type_code = T3.charge_type WHERE T3.charge_amount > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = \"veterinarian\" UNION SELECT first_name FROM professionals WHERE role_code = \"guardian\" EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = \"veterinarian\" UNION SELECT first_name FROM professionals WHERE role_code = \"guardian\" EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"medical care\" EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT id , role_code , email_address FROM Professionals EXCEPT SELECT T1.id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.role_code , T1.first_name , T1.last_name , T1.professional_id FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.role_code , T1.first_name , T1.last_name , T1.professional_id FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatment_Types AS T3 ON T2.dog_id = T3.dog_id WHERE T3.treatment_type_code = 'P' GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN treatment_types AS T2 ON T1.breed_name = T2.treatment_type_code WHERE T2.charge_type = \"Health\" ORDER BY sum(T3.charge_amount) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Treatment_Types AS T2 ON T1.breed_code = T2.breed_code JOIN charges AS T3 ON T3.charge_type = 'health' JOIN charges AS T4 ON T4.charge_type = 'medical' WHERE T3.charge_amount = (SELECT min(charge_amount) FROM charges WHERE charge_type = 'health') AND T4.charge_amount = (SELECT min(charge_amount) FROM charges WHERE charge_type = 'medical')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.cell_number , T1.professional_id FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.breed_code , T1.breed_name FROM Breeds AS T1 JOIN Professionals AS T2 ON T1.breed_code = T2.professional_id JOIN Treatment_Types AS T3 ON T3.treatment_type_code = T2.professional_id GROUP BY T1.breed_code HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.date_of_birth < (SELECT min(date_of_birth) FROM dogs) AND sum(T2.cost_of_treatment) < (SELECT sum(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatment_Types)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_birth , T4.first_name FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id JOIN Professionals AS T3 ON T2.professional_id = T3.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Charges AS T1 JOIN Treatment_Types AS T2 ON T1.charge_type = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM charges AS T1 JOIN treatment_types AS T2 ON T1.charge_type = T2.charge_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_description FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.breed_code = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.size FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.first_name = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.breed_name , T2.date_of_treatment FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T1.breed_name = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T4.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id JOIN Professionals AS T3 ON T2.professional_id = T3.professional_id JOIN breeds AS T4 ON T1.breed_code = T4.breed_code WHERE T4.breed_name = \"Rare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city AND T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.name , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatment_Types AS T2 ON T1.breed_code = T2.treatment_type_code WHERE T2.treatment_type_description = \"medical care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatment_Types AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Health\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM Dogs) AND T2.gender = \"M\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" INTERSECT SELECT email_address FROM Professionals WHERE state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.treatment_type_code = \"healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = \\\"P\";}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"P\" AND T.treatment_type_code = \"health\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = \"Puppie\" AND role_code = \"Veterinary\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT T2.role_code , T2.street , T2.city , T2.state FROM Professionals AS T1 JOIN Owners AS T2 ON T1.professional_id = T2.owner_id WHERE T2.city LIKE \"%West%\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = \"P\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.first_name != \"Pups\" AND T2.age != 1 AND T2.date_arrived != \"2023-12-15 00:00:00\" AND T2.date_departed != \"2023-12-15 00:00:00\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE gender = \"dog\" AND abandoned_yn = \"yes\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE dog_id = \"puppies\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = \"Veterinarian\" EXCEPT SELECT count(*) FROM treatments AS T1 JOIN dog_id AS T2 ON T1.dog_id = T2.dog_id WHERE T2.gender = \"P puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE breed_code = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE breed_code = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs WHERE breed_code = \"Psi\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charge_amount) FROM charges WHERE charge_type = \"VIP\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM PROFESSIONALS WHERE role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_name , size_description FROM Digs JOIN sizes ON dogs.size_code = sizes.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.age = \"Pup\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T2.role_code , T2.treatment_type_description FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer WHERE Citizenship = \"Country\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY net_works_minillions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT count(*) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Title FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Country FROM singer GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 3000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 3000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.name , sum(T1.sales) FROM song AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT country FROM singer WHERE birth_year < 1945 INTERSECT SELECT country FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT feature_type_name FROM Other_Available_Features WHERE feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T2.property_type_description FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT T1.property_name FROM properties AS T1 JOIN Other_Property_Features AS T2 ON T1.property_id = T2.property_id WHERE T2.apt_feature_1 = 'apartment' AND T1.room_count > 1 UNION SELECT T1.property_name FROM properties AS T1 JOIN Other_Property_Features AS T2 ON T1.property_id = T2.property_id WHERE T2.apt_feature_1 = 'house'", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..9e261b42ab58b6f212e6073e50ad0414b0dbf61d --- /dev/null +++ b/infer/qwen/spider_syn/csd_train_0.6b_4b_kd0.6_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.6-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer WHERE is_male = 'female' ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , COUNT(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , T1.State FROM stadium AS T1 JOIN singer_in_concert AS T2 ON T1.stadium_id = T2.stadium_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T1.State", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.stadium_id FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year > 2013 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.year FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T1.singer_id = T3.singer_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T1.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT min(weight) FROM Pets WHERE pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , petage , pettype FROM Pets WHERE pettype = 'Domestic' GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T3.PetID = T2.PetID WHERE T1.sex = 'F' AND T3.pettype = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Sex = 'F' JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets WHERE pettype = \"domestic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT species) FROM animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = T2.pet_age AND T3.pet_type = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID NOT IN (SELECT PetID FROM Pets WHERE pettype = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_age , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pet_age > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T3.StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T3.StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID JOIN Student AS T3 ON T1.StuID = T3.StuID WHERE T3.LName = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , T1.StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID GROUP BY T1.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , COUNT(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.contid , T1.continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.contid = T2.continent GROUP BY T1.continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make IN (SELECT make FROM cars_data ORDER BY horsepower LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid ORDER BY T2.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.Maker , t2.Year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.Model WHERE t2.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT count(*) , T1.Continent FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country JOIN countries AS T3 ON T3.CountryId = T2.Country WHERE T2.Maker = \"Ford\" GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country ID GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.continent FROM continents AS t1 JOIN car_makers AS t2 ON t1.countryname = t2.country WHERE t2.id = (SELECT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.countryid GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.maker , T1.fullname FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.full_name FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T1.Maker = \"Amc hornet sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'Ford' AND model = 'F-150 Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName LIKE \"%French%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryname WHERE T2.continent = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT maker , model FROM model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT maker , model FROM model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryId HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T2.Id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Maker GROUP BY T2.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT AVG(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , avg(year) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.Continent FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country WHERE T1.Continent = \"Europe\" GROUP BY T1.Continent HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T2.cylinders = 3 GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T2.maker FROM cars_data AS T1 JOIN model_list AS T2 ON T1.id = T2.model WHERE T1.cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Model = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , max(Cylinders) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = 'Make' GROUP BY t2.model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT DISTINCT model FROM model_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.Weight > 3500 OR T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "{\"sql\": \"SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T1.Maker = \\\"General Motors\\\" INTERSECT SELECT DISTINCT T2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Accelerate) , max(Cylinders) FROM cars_data WHERE make = 'volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND Model = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers GROUP BY maker HAVING count(DISTINCT maker) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = 'Ford' AND cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"4 Cylinder\" GROUP BY model ORDER BY max(horsepower) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE id NOT IN (SELECT makeid FROM cars_data ORDER BY horsepower LIMIT 1) AND cylinders > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE countryid = (SELECT countryid FROM cars_data WHERE horsepower < 4 AND cylinders != 4)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM model_list WHERE weight < 3500 AND maker != 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries EXCEPT SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.countryid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.id , T1.countryname FROM cars_data AS T1 JOIN car_names AS T2 ON T1.makeid = T2.modelid JOIN model_list AS T3 ON T2.model = T3.model WHERE T3.Maker = 'FIAT' GROUP BY T1.id HAVING count(*) > 3 UNION SELECT T1.id , T1.countryname FROM cars_data AS T1 JOIN car_names AS T2 ON T1.makeid = T2.modelid JOIN model_list AS T3 ON T2.model = T3.model WHERE T3.Maker = 'Car' GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country JOIN cars_data AS T3 ON T2.id = T3.makeid GROUP BY T1.countryname HAVING count(*) > 3 UNION SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country JOIN cars_data AS T3 ON T2.id = T3.makeid WHERE T3.model = 'Fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.country FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.FlightNo = 1111", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT abbreviation FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , airportcode FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirportName , T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(T2.FlightNo) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T2.airportcode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportCode = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = 'Alton'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'Terminal ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'ATO' OR destairport = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'City Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Aberdeen' AND T1.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Aline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Aline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.destairport = T3.airportcode WHERE T1.airline = 'United Airlines' AND T3.airportname = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.destairport WHERE T3.airportname = \"ASY Airport\" AND T1.airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.sourceairport = T3.airportcode WHERE T3.airportname = 'AHD' AND T1.abbrv = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.airportname = \"AHD\" AND T1.abbr = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T2.destairport = T3.airportcode WHERE T3.city = 'Aberdeen' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"United\" AND T2.destairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportName ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T2.SourceAirport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.sourceairport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airway FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode GROUP BY T1.Airway ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Shortword , T2.State FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode GROUP BY T2.State ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportname , T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.airline = 101", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'CVO' EXCEPT SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.SourceAirport WHERE T1.Airway = 'CVO' EXCEPT SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.SourceAirport WHERE T1.Airway = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.airline , T1.FlightNo FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' OR T2.city = 'Abilene'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = 'Aberdeen' OR T1.city = 'Abilene'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destinationairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destinationairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , district FROM shop GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , district FROM shop GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , district FROM shop GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.district FROM shop AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM market GROUP BY name , district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , LOCATION FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T2.bonus = (SELECT max(bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T2.name FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T1.year_awarded = 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id ORDER BY T1.employee_id , T2.number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE manager_name NOT IN (SELECT employee_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T2.manager_name , count(*) FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T2.manager_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T1.year_awarded = 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(Bonus) FROM evaluation", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT DISTINCT district FROM shop WHERE number_products < 3000 INTERSECT SELECT DISTINCT district FROM shop WHERE number_products > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.Template_ID , T1.Template_Details , T1.Template_Details FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT t1.template_id , t1.name , t1.description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_name , T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.template_id , t2.layout_id , t1.template_details FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id JOIN Templates AS t3 ON t1.template_id = t3.template_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.template_id , t2.layout_id , t2.template_details FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id JOIN Templates AS t3 ON t1.template_id = t3.template_id WHERE t3.template_details = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs WHERE paragraph_text LIKE '%text%' AND template_type_code = 'PPT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id JOIN Ref_Template_Types AS T3 ON T2.template_type_code = T3.template_type_code WHERE T3.template_type_description = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Paragraphs GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , layout_id FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_id , template_type_code FROM layouts AS T1 JOIN ref_template_types AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT template_id FROM paragraphs GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM layouts EXCEPT SELECT t1.template_id FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t2.paragraph_text = 'paper'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT template_id , version_number , template_type_description FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT layout_type_description FROM Ref_Template_Types AS T1 JOIN Layouts AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id WHERE T3.template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM layouts WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type_name FROM layouts WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT count(*) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_description ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types GROUP BY template_type_description HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Layouts AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , min(template_type_code) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT layout_type_code FROM layouts WHERE name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.other_details = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT DISTINCT t1.document_name FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id JOIN Templates AS t3 ON t1.template_id = t3.template_id WHERE t3.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT t1.document_name FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id WHERE t2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT t1.template_type_description , count(*) FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_description", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , T1.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_description ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM paragraphs WHERE paragraph_text LIKE \"%text%\" GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types EXCEPT SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.template_type_code = t2.template_id EXCEPT SELECT t3.template_type_description FROM Ref_Template_Types AS t3 JOIN Paragraphs AS t4 ON t3.template_type_code = t4.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types EXCEPT SELECT t2.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.paragraph_text = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT t2.template_type_description , t1.template_details FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT t2.template_type_description , t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t2.layout_type_name FROM Ref_Template_Types AS t1 JOIN layout_types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t2.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Paragraphs AS T3 ON T2.template_id = T3.document_id WHERE T3.paragraph_text LIKE \"%text%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM Ref_Template_Types WHERE template_type_description = \"Presentation\" UNION SELECT layout_id FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT template_id FROM Paragraphs WHERE paragraph_text LIKE '%Presentation%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Welcome to NY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT paragraph_text FROM paragraphs WHERE document_id IN (SELECT document_id FROM documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Customer reviews'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT count(*) , T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.template_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT T1.template_id , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT count(*) , T1.document_id , T2.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT t1.template_id , t1.document_name , count(*) FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_details FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT t1.template_id FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t1.template_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT template_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.Template_ID FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T2.Paragraph_Text = 'Brazil' INTERSECT SELECT T1.Template_ID FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T2.Paragraph_Text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Brazil' INTERSECT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.grade FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.COURSE = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.COURSE = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE level_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_of_membership FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.ID , T2.Name , T2.Age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID GROUP BY T2.ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.ID , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID WHERE T1.Total_spent = (SELECT max(T1.Total_spent) FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(Num_of_Ticket) , max(Num_of_Ticket) FROM visit", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT T2.Total_spent FROM visitor AS T1 JOIN visit AS T2 ON T1.visitor_id = T2.visitor_id WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id JOIN museum AS T3 ON T3.Museum_ID = T1.Museum_ID WHERE T3.Open_Year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id JOIN museum AS T3 ON T3.Museum_ID = T1.Museum_ID WHERE T3.Open_Year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE ID NOT IN (SELECT T2.ID FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID WHERE T2.Open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM rankings", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches ORDER BY loser_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_date LIKE \"%2013%\" OR tourney_date LIKE \"%2016%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , state_abbr FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T2.tourney_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.tourney_name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.ranking_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY sum(T2.ranking_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id WHERE T3.tourney_name = \"Australian Open\" ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id WHERE T2.tours = \"Australian Open\" ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.loser_name , T1.winner_name FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , avg(T2.ranking) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.ranking_points) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.abbr FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T2.abbr ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM matches GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.ranking FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_hand) FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.hand = \"left\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(cause_by_ship_id) , min(cause_by_ship_id) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T2.casualty , T2.injured FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T1.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.lost_in_battle = T2.id WHERE T1.ship_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE result = 'loss' EXCEPT SELECT count(*) FROM ship WHERE tonnage = 225", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE lost_in_battle NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM addresses WHERE line_1 = 'line 1' AND line_2 = 'line 2'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%Math%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T2.department_id FROM departments AS T1 JOIN degree_programs AS T2 ON T1.department_id = T2.department_id GROUP BY T2.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM degree_programs WHERE department_id IN (SELECT department_id FROM departments WHERE department_name = 'Engineering')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments WHERE department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T2.student_id = T3.student_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT T2.course_description FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id WHERE T1.course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT T2.department_description FROM courses AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id WHERE T1.course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T2.semester_id = 1 AND T2.degree_program_id = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Undergraduate' AND T2.semester_id = 1 GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.department_name = 'Bachelor\\'s Degree'}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T2.degree_program_id = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , count(*) FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.degree_summary_name FROM Student_Enrolment AS T1 JOIN Degree_Programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T2.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id , count(*) FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T2.semester_name FROM courses AS T1 JOIN semesters AS T2 ON T1.course_id = T2.course_id WHERE T1.course_name = 'Academic Session' EXCEPT SELECT T3.semester_name FROM courses AS T3 JOIN student_enrolment AS T4 ON T3.course_id = T4.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" INTERSECT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" AND T2.student_id NOT IN (SELECT T2.student_id FROM degree_programs AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id JOIN student_enrolment AS T3 ON T3.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM students AS T1 JOIN student_enrolment_courses AS T2 ON T1.student_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT date_first_registered FROM students ORDER BY date_first_registered LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.line_1 , T2.line_2 , T2.line_3 , T2.city , T2.zip_postcode , T2.state_province_county FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , 'First student record' FROM students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , other_details FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_left) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_first_registered) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.course_id FROM Student_Enrolment_Courses AS T1 JOIN Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(T2.student_enrolment_id) , T1.course_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM students AS T1 JOIN transcript_contents AS T2 ON T1.student_course_id = T2.student_course_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = 'Master' INTERSECT SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Masters' INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.address_id) FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T2.city FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM students ORDER BY first_name,last_name REVERSE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_name FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT course_description FROM sections WHERE section_name = 'h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.country = 'Haiti' UNION SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id AND T2.cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id IN (SELECT T1.permanent_address_id FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.country = 'Haiti') OR cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T2.channel , T1.series_name FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.id WHERE T1.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.channel FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t3.title FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel JOIN tv_series AS t3 ON t1.id = t3.channel WHERE t1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT * FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.episode , T1.rating FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id ORDER BY T1.rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT air_date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT air_date FROM TV_series WHERE episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.channel , T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t2.title FROM tv_series AS t1 JOIN cartoon AS t2 ON t1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"High Definition\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Animated series\" AND T3.write_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE written_by = 'Todd Casey')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT state FROM cartoon EXCEPT SELECT T1.state FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.title , t1.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Ben Jones\" INTERSECT SELECT t1.title , t1.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM TV_channel WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T2.package_option FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.id = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T1.Package_Option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Name = \"Car gamer\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Name = \"Car gamer\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID = people.ID AND Nationality = \"Car\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM people WHERE Nationality = \"American\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"gamers\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"gamers\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T1.Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = 'Car Game')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Earnings = 10000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(*) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name != 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT T2.state , T1.created FROM votes AS T1 JOIN area_code_state AS T2 ON T1.state = T2.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM votes AS T1 JOIN area_code_state AS T2 ON T1.state = T2.state WHERE T2.state = 'NY' OR T2.state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.area_code FROM VOTES AS T1 JOIN AREA_CODE_STATE AS T2 ON T1.state = T2.state GROUP BY T1.state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.state , T1.phone_number , T1.created FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 'Tabatha Gehling' INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE indepyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Name = \"South Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"english\" AND T1.Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode JOIN city AS t3 ON t1.name = t3.name WHERE t3.name = 'Anguilla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.region FROM country AS T1 JOIN city AS T2 ON T1.code = T2.capital WHERE T2.name = \"Kabul\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = (SELECT countrycode FROM city WHERE name = 'Aruba') GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'ARU'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.Population , T1.LifeExpectancy FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.Population , T2.LifeExpectancy FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Population , T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(t2.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND Region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = 'Africa' AND Region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT Population FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE governmentform = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND code = 'AFR'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND countrycode = 'AFR'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country WHERE language = \"English\" INTERSECT SELECT count(*) FROM country WHERE language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name , T2.name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.isofficial = 1 AND T1.language = \"english\" INTERSECT SELECT T1.name , T2.name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.isofficial = 1 AND T1.language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = 'China'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia' GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language HAVING count(*) = 1 AND countrycode = (SELECT countrycode FROM countrylanguage GROUP BY countrycode ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE isofficial = 1 GROUP BY language HAVING count(*) = 1 INTERSECT SELECT language FROM countrylanguage WHERE isofficial = 1 AND governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"english\" GROUP BY T1.name ORDER BY sum(T1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.continent = 'Asia' ORDER BY T1.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.Code2 = T2.CountryCode WHERE T1.Continent = \"Asia\" ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Code NOT IN (SELECT CountryCode FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE isofficial = 1 AND independyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.StateAbbreviation FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" EXCEPT SELECT T1.StateAbbreviation FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE governmentform != 'Republic' AND language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE governmentform != 'Republic' AND language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T3.isofficial = 0 AND T2.name = \"Europe\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" EXCEPT SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.Language = \"Chinese\" AND T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T3.isofficial = 1 AND T2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.name , T1.indepyear , T1.continent FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code ORDER BY T2.population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.name , T1.indepyear , T1.continent FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code ORDER BY T2.population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT capital , name FROM country ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T2.HeadOfState FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.code ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT governmentform , count(*) FROM country WHERE lifeexpectancy > 72 GROUP BY governmentform", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT governmentform , sum(population) FROM country WHERE lifeexpectancy > 72 GROUP BY governmentform", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) , continent FROM country WHERE avg(lifeexpectancy) < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT continent , sum(population) , avg(lifeexpectancy) FROM country WHERE lifeexpectancy < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , region FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = \"Europe\" AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.surfacearea) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.surfacearea) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage GROUP BY Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage GROUP BY Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.State FROM countrylanguage AS T1 JOIN state AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T2.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Percentages) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM country WHERE countrylanguage% >= 50 AND language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor WHERE year_of_work = 100 ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE age = (SELECT max(age) FROM conductor)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T3.name , T2.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id JOIN show AS T3 ON T1.performance_id = T3.performance_id WHERE T3.if_first_show = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T3.name , T2.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id JOIN show AS T3 ON T1.performance_id = T3.performance_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , COUNT(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , record_company FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT T1.record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.record_company ORDER BY count(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT major_record_format FROM orchestra GROUP BY major_record_format ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT T1.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra = T2.orchestra_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.year_of_founded FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T2.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT T1.id , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(DISTINCT T1.name) , T2.student_id FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 9999", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(DISTINCT T2.friend_id) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friend INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T1.id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id WHERE T3.friend_id IN (SELECT T4.id FROM highschooler AS T4 JOIN friend AS T5 ON T4.id = T5.student_id GROUP BY T5.student_id HAVING count(*) >= 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.id FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.id FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T2.name , count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T2.name FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T3.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id JOIN student_profile AS T3 ON T1.student_id = T3.id WHERE T2.grade > 5 GROUP BY T3.id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T3.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id JOIN student_info AS T3 ON T1.student_id = T3.student_id WHERE T2.grade > 5 GROUP BY T3.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN student_id AS T3 ON T2.liked_id = T3.id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T2.grade) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friends)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = 'guardian' INTERSECT SELECT state FROM owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT DISTINCT state FROM Professionals WHERE role_code = 'guardian' INTERSECT SELECT DISTINCT state FROM Professionals WHERE role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.treatment_type_code = \"medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.date_of_treatment LIKE \"%health care%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.cell_number FROM OWNERS AS T1 JOIN PROFESSIONALS AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T1.owner_id , T1.first_name , T1.cell_number FROM OWNERS AS T1 JOIN PROFESSIONALS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = \"Veterinarian\" GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" OR T2.role_code = \"health_care\" GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN charges AS T3 ON T2.cost_of_treatment = T3.charge_amount WHERE T3.charge_amount > 1000 AND T2.treatment_type_code = \"Health-care\" AND T1.gender = \"Dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT T1.first_name FROM professionals AS T1 JOIN dogs AS T2 ON T1.professional_id = T2.professional_id WHERE T2.name LIKE '%dog%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM PROFESSIONALS WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT T1.first_name FROM professionals AS T1 JOIN dogs AS T2 ON T1.professional_id = T2.professional_id WHERE T2.name = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'dog' EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'dog' AND T2.treatment_type_code = 'medical'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , role_code , email_address FROM professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM OWNERS AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id ORDER BY T3.cost_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.professional_id , T1.owners.first_name , T1.owners.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id ORDER BY T3.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.treatment_type_description FROM charges AS t1 JOIN treatment_types AS t2 ON t1.charge_type = \"health-care\" JOIN treatment_types AS t2 ON t1.charge_type = \"health-care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t1.treatment_type_description FROM Treatment_Types AS t1 JOIN treatments AS t2 ON t1.treatment_type_code = t2.treatment_type_code GROUP BY t2.treatment_type_code ORDER BY sum(t2.cost_of_treatment) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = 'veterinarian' GROUP BY T1.owner_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = \"Veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = \"operating\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments WHERE charge_type = 'health-care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.size_description FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T2.size_code = T3.size_code WHERE T2.owner_id = T6.professional_id AND T6.role_code = 'guardian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_description FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.last_name = \"Puppy\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T3.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id WHERE T3.treatment_type_code = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = 'pug' AND T2.date_of_treatment = (SELECT min(date_of_treatment) FROM Treatments WHERE treatment_type_code = 'healthcare')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T3.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.treatment_type_description = 'Medical Care' ORDER BY T3.date_of_treatment LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'VA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'VA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE dog_id IN (SELECT dog_id FROM treatments WHERE treatment_type_code = 'Medical Care')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Health\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs) AND T2.gender = 'shih tzu'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE role_code = \"Veterinarian\" AND state = \"Hawaii\" UNION SELECT email_address FROM professionals WHERE role_code = \"Veterinarian\" AND state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = \"health care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM dogs WHERE gender = 'P' AND (SELECT count(*) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.treatment_type_code = 'Healthcare' ) > 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.role_code) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.age >= 1 AND T2.gender = 'dog' AND T2.name = 'puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.role_code) FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = 'Veterinarian' AND T1.treatment_type_code = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(charge_amount) FROM charges WHERE charge_type = 'health-care' AND date_of_treatment = (SELECT max(date_of_treatment) FROM charges WHERE charge_type = 'health-care')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1) AND charge_type = 'medical'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE gender = 'Puppy' AND dog_id NOT IN ( SELECT dog_id FROM treatments WHERE treatment_type_code = 'Medical Care' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.first_name = \"Guardian\" AND T2.age < 10 EXCEPT SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.first_name = \"Guardian\" AND T2.age < 10 AND T2.name = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM OWNERS WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs WHERE age < 30 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = 'veterinarian' AND professional_id NOT IN ( SELECT professional_id FROM treatments AS T1 JOIN dog AS T2 ON T1.dog_id = T2.dog_id WHERE T2.age < 10 );", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = 'veterinarian' EXCEPT SELECT count(*) FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T3.dog_id = T1.dog_id WHERE T3.gender = 'dog' AND T3.age >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE gender = 'dog' AND breed_code = 'puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'dog' AND breed_code = 'dog';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE gender = 'dog' AND date_of_birth - age = (SELECT max(age) FROM dogs WHERE gender = 'dog')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE gender = 'P' ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T2.breed_name , T3.size_description FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T1.size_code = T3.size_code WHERE T1.gender = \"P\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.description FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"Medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.role_code , T2.treatment_type_description FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT T1.Birth_Year , T1.Citizenship FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT COUNT(*) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Country FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.citizenship FROM singer AS t1 JOIN song AS t2 ON t1.singer_id = t2.singer_id GROUP BY t1.singer_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_worth_millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(net_worth_millions) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , T1.Sales FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT feature_type_name FROM Other_Available_Features WHERE feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T2.property_type_description FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code WHERE T1.property_type_code = (SELECT property_type_code FROM properties WHERE property_type_code = (SELECT property_type_code FROM properties GROUP BY property_type_code HAVING count(*) > 1))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..222b77abf32099cd925b5f3a7cd79d969f67fa54 --- /dev/null +++ b/infer/qwen/spider_syn/csd_train_0.6b_4b_spider_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer WHERE is_male = 'female' ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , State FROM musician GROUP BY State", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.year FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 40 INTERSECT SELECT DISTINCT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.concert_Name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T2.concert_Name , T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN song_as_T2 AS T3 ON T1.song_release_year = T3.song_release_year WHERE T3.song_title LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id WHERE T2.song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.Highest = (SELECT highest FROM stadium ORDER BY capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets) AND pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , petage , pettype FROM pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Sex = \"F\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.sex , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid NOT IN (SELECT petid FROM Pets WHERE pettype = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T3.PetID = T2.PetID WHERE T3.PetType = \"Puppy\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T3.PetID = T2.PetID WHERE T3.PetType = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(age) , max(age) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.Fname , T2.Lname , T2.Age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Mammal\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.StuID FROM Has_Pet AS T1 JOIN Students AS T2 ON T1.StuID = T2.StuID WHERE T2.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.StuID FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Fname , T2.Lname , T2.Sex FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.LName FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.LName FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Students WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T2.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY max(horsepower) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = 'Ford' ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM car_names WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM car_names WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT t1.FullName FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.Id = t2.Id WHERE t2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.Year FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Id ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , COUNT(*) FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.Continent = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.countryid GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Maker = \"Amc\" AND T2.Model = \"Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE model = \"ACHTER\" AND make = \"MOTORIZED\" AND sportabout = \"SW\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName LIKE \"%French%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT t1.FullName , t2.Id FROM car_makers AS t1 JOIN countries AS t2 ON t1.Country = t2.CountryId GROUP BY t2.Id HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.Continent FROM continents AS T1 JOIN countries AS T2 ON T1.Continent = T2.Continent WHERE T2.CountryName = \"Europe\" GROUP BY T1.Continent HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T2.cylinders = 3 GROUP BY T1.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , make FROM cars_data WHERE cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY sum(mpg) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = 'Ford' ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE model = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Maker FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Make = \"Make\" GROUP BY T1.Make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT maker FROM model_list GROUP BY maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullname = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T1.FullName = \"General Motors\" OR T2.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Weight > 3500 UNION SELECT DISTINCT T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Cylinders) FROM cars_data WHERE Model = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(alculate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT T1.Maker) FROM car_makers AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Maker WHERE count(DISTINCT T1.Maker) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE id > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = 'Ford' AND cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"4 Cylinder\" GROUP BY model ORDER BY max(horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullName FROM car_makers WHERE id IN (SELECT id FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data)) EXCEPT SELECT makeid , fullName FROM car_makers WHERE cylinders > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE id NOT IN (SELECT makeid FROM cars_data WHERE horsepower >= 100 AND cylinders <= 4)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.id = T2.id WHERE T1.maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.CountryName NOT IN (SELECT T3.CountryName FROM cars_data AS T3 JOIN car_makers AS T4 ON T3.MakeId = T4.Id GROUP BY T4.Maker HAVING COUNT(*) = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country JOIN model_list AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat' OR COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Ford\" INTERSECT SELECT T1.Id , T1.FullName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \" Fiat \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , countryabbreviation FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirportName , T1.AirportCode FROM airports AS T1 JOIN airlines AS T2 ON T1.AirportCode = T2.AirportCode WHERE T2.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(airportcode) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = 'Aberdeen' AND T1.DestAirport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Ashley\" AND T1.SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY Airport\" AND T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'AHD' AND T1.Airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\" AND T1.Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'Aberdeen' JOIN airlines AS T3 ON T1.SourceAirport = T3.Airline WHERE T3.Abbreviation = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" AND T1.Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportName , T1.CountryAbbrev FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.CountryAbbrev ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Airline , T1.AirportCode , T1.AirportName , T1.CountryAbbrev FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.SourceAirport GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN airports AS T2 ON T1.Airline = T2.airline WHERE T2.airportname = \"AHD\" INTERSECT SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.airline WHERE T2.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airway FROM airlines AS T1 JOIN airports AS T2 ON T1.Airline = T2.Airline WHERE T2.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'APG' INTERSECT SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T1.airportcode = T3.airportcode WHERE T3.airportname = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T1.airportcode = T3.airportcode WHERE T3.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'CVO' EXCEPT SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline , T1.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T1.SourceAirport = 'CVO' EXCEPT SELECT T1.Airline , T1.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T1.SourceAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.AirportCode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.airline , T1.flightno FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.sourceairport WHERE T1.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.SourceAirport WHERE T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.CountryAbbrev = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = \"Aberdeen\" OR T1.city = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee GROUP BY city HAVING age < 30 COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T2.Manager_name , T2.District FROM shop AS T1 JOIN hiring AS T2 ON T1.Shop_ID = T2.Shop_ID GROUP BY T1.Shop_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM shop GROUP BY name , district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , city FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.is_full_time DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE manager_name != 'has workers'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T1.name FROM shop AS T1 JOIN hiring AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT DISTINCT district FROM shop WHERE number_products < 3000 INTERSECT SELECT DISTINCT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_name , T1.document_layout_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.document_id , t1.layout_id , t2.document_description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.document_id , t1.layout_id , t2.document_description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs WHERE template_type_code = 'PPT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Paragraphs GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Templates AS T1 JOIN DocumentTemplates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Templates AS T1 JOIN DocumentTemplates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT template_id FROM paragraphs GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT template_id FROM documents GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM layouts EXCEPT SELECT t1.template_id FROM layouts AS t1 JOIN papers AS t2 ON t1.template_id = t2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT template_id , version_number , template_type_description FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM Templates WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type_name FROM Templates WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT count(*) , layout_type FROM templates GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_description ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types GROUP BY template_type_description HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT template_type_description FROM ref_template_types EXCEPT SELECT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_description HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Template_Type_Code) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id WHERE t2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN documents AS t3 ON t2.template_id = t3.template_id WHERE t3.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT t1.document_name FROM documents AS t1 JOIN templates AS t2 ON t1.template_id = t2.template_id WHERE t2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT t1.document_name FROM documents AS t1 JOIN templates AS t2 ON t1.template_id = t2.template_id WHERE t2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.template_type_description , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_description", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT layout_type_code , count(*) FROM Templates GROUP BY layout_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT layout_type_description FROM Paragraphs GROUP BY layout_type_description ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types EXCEPT SELECT DISTINCT t2.template_type_description FROM Paragraphs AS t1 JOIN Templates AS t2 ON t1.document_id = t2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT template_type_description FROM ref_template_types EXCEPT SELECT t1.template_type_description FROM ref_template_types AS t1 JOIN paragraphs AS t2 ON t1.template_type_code = t2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.template_type_description , T2.template_type_name FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.template_type_description , T2.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM ref_template_types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM ref_template_types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.layout_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.layout_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT template_type_code FROM ref_template_types WHERE template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Paragraphs AS T3 ON T2.template_id = T3.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM templates AS T1 JOIN ref_template_types AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_description = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT paragraph_text FROM paragraphs WHERE document_id IN (SELECT document_id FROM documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T2.paragraph_text FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Customer reviews'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT T1.document_id , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT count(*) , T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT count(*) , T1.document_id , T2.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.paragraph_id , T1.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT T1.template_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.template_id FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Brazil' INTERSECT SELECT T1.template_id FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Grade FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course , T1.Curriculum FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT DISTINCT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course ) = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE level_of_membership > 4 ORDER BY level_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE level_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , level_of_membership FROM visitor WHERE level_of_membership > 4 ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT Museum_ID , Name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.ID , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID WHERE T1.total_spent = (SELECT max(total_spent) FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.Total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.visitor_id = T2.visitor_id WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T3.Museum_ID = T1.Museum_ID WHERE T3.Open_year < 2011 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T3.Museum_ID = T1.Museum_ID WHERE T3.Open_year > 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT T1.visitor_id FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id WHERE T2.open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM rankings", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id WHERE T3.year = 2013 INTERSECT SELECT T1.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id WHERE T3.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , last_name , lowest_rank FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'yes' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T2.tourney_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.tourney_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id WHERE T3.tourney_name = \"Australian Open\" ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT loser_name , winner_name FROM matches ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM players GROUP BY state_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.abbr FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.abbr ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_hand) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = 'left' INTERSECT SELECT count(DISTINCT T1.winner_hand) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = 'right'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = 'left' AND T2.tourney_name = 'WTA Championships'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code , T2.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(killed) , min(killed) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T1.disposition_of_ship , T2.note FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T1.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE result = 'not lost'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM addresses WHERE line_1 = 'line 1' INTERSECT SELECT address_id FROM addresses WHERE line_2 = 'line 2'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name = 'Math Curriculum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%Math%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.department_name FROM degree_programs AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id GROUP BY T2.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_program_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments WHERE department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.student_enrolment_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.student_id IN (SELECT student_id FROM students GROUP BY student_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT department_description FROM departments WHERE department_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = '2 degree programs'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = '2' GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor\\'s Degree'\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , count(*) FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id , count(*) FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = 'North Carolina' EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id JOIN student_enrolment AS T3 ON T1.address_id = T3.current_address_id JOIN degree_programs AS T4 ON T3.degree_program_id = T4.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE current_address_id IN (SELECT T1.line_1 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\") EXCEPT SELECT last_name FROM students WHERE student_id IN (SELECT T1.student_id FROM student_enrolment AS T1 JOIN degree_programs AS T2 ON T1.student_id = T2.student_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM students AS T1 JOIN transcript_contents AS T2 ON T1.student_course_id = T2.student_course_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Courses AS T3 ON T2.course_id = T3.course_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.line_1 , T3.line_2 , T4.line_3 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id JOIN Transcripts AS T3 ON T3.transcript_id = T2.student_id JOIN Departments AS T4 ON T4.department_id = T3.department_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM Transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered FROM students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , other_details FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_left) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_left) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(count(*) , T1.student_enrolment_id) , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(T2.student_enrolment_id) , T1.course_id FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM students AS T1 JOIN transcripts AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM students AS T1 JOIN transcripts AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Master' INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Masters' INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT current_address_id) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T1.line_1 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM students ORDER BY first_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_name FROM sections WHERE section_name = 'h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name , last_name FROM students WHERE cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id = (SELECT permanent_address_id FROM addresses WHERE country = 'Haiti') OR cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.id WHERE T1.written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name , content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , count(*) FROM TV_channel GROUP BY Language ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t2.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t2.series_name FROM cartoon AS t1 JOIN tv_channel AS t2 ON t2.id = t1.channel WHERE t1.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.title FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT * FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.episode , T1.rating FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id ORDER BY T1.rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT original_air_date FROM cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Weekly_Rank FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.channel WHERE T1.title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.channel FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t1.series_name FROM TV_series AS t1 JOIN TV_channel AS t2 ON t1.channel = t2.id WHERE t2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.episode FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.channel = T2.channel WHERE T2.directed_by = \"Todd Casey\" AND T2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT state FROM cartoon EXCEPT SELECT T1.state FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.id WHERE T1.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.State FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.State FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.Series_name , T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T2.package_option FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T2.Package_Option FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.Channel = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Final_Table_Made = \"Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM car_gameer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Name = \"Car Gamers\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Best\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT nationality FROM people GROUP BY nationality ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Earnings = 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Earnings = 100)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS EXCEPT SELECT 'Jessie Alloway' FROM CONTESTANTS", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT T1.state , T2.set_up_time FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.created = (SELECT max(created) FROM votes)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T1.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.contestant_number , T1.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T2.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.set_up_date , T2.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number = (SELECT T3.contestant_number FROM CONTESTANTS AS T3 WHERE T3.contestant_name = 'Tabatha Gehling') INTERSECT SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number = (SELECT T3.contestant_number FROM CONTESTANTS AS T3 WHERE T3.contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independeyyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE indepyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Repub\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T2.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t2.SurfaceArea) FROM country AS t1 JOIN city AS t2 ON t1.Code = t2.CountryCode WHERE t1.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = 'AF' AND name = 'Anguilla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = 'AF'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.CountryName = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = (SELECT countrycode FROM city WHERE name = 'Aruba')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.Population , T1.LifeExpectancy FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE name = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND lifeexpectancy = (SELECT min(lifeexpectancy) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT headOfState FROM country WHERE continent = 'Asia' ORDER BY LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(population) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(t2.SurfaceArea) FROM country AS t1 JOIN city AS t2 ON t1.Code = t2.CountryCode WHERE t1.Continent = \"Asia\" OR t1.Continent = \"Europe\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT Population FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnpoold) , count(*) FROM country WHERE GovernmentForm = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Afghanistan' AND T1.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Afghanistan' AND T1.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t2.countrycode ORDER BY sum(t2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.Language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"English\" INTERSECT SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Continent FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Continent FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.Language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.GovernmentForm = \"Republic\" GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.Language = \"English\" GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" GROUP BY T1.Name ORDER BY SUM(T1.Population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code WHERE T1.continent = 'Asia' ORDER BY T1.surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T2.lifeexpectancy FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.continent = 'Asia' ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.name NOT IN (SELECT T1.code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT isofficial) FROM countrylanguage WHERE code -> (SELECT code FROM country WHERE independyr < 1930)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' INTERSECT SELECT name FROM country WHERE population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' INTERSECT SELECT name FROM country WHERE population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT t1.name FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT capital FROM city WHERE population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT state FROM countrylanguage WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country EXCEPT SELECT t1.code FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.Language = \"English\" AND t2.GovernmentForm != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT HeadOfState FROM country WHERE GovernmentForm != 'Republic' AND IsOfficial = 0 UNION SELECT Language FROM countrylanguage WHERE IsOfficial = 0 AND Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0 EXCEPT SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = 0 AND T1.CountryCode = \"EU\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.Continent = \"Asia\" AND T3.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.name , T1.indepyear , T1.continent FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode ORDER BY T2.population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.name , T1.headofstate FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.surfacearea = (SELECT max(surfacearea) FROM country) GROUP BY T1.name , T1.headofstate", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.population , t1.headofstate FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code ORDER BY t1.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT governmentform , count(*) FROM country WHERE lifeexpectancy > 72 GROUP BY governmentform", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT GovernmentForm , COUNT(*) FROM country WHERE LifeExpectancy > 72 GROUP BY GovernmentForm", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) , continent FROM country WHERE avg(lifeexpectancy) < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT continent , count(*) , avg(lifeexpectancy) FROM country WHERE avg(lifeexpectancy) < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , region FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Europe\" AND T2.Population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Europe\" AND T2.Population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T2.SurfaceArea) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"North America\" AND T2.Population > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T2.Territory) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"North America\" AND T2.Territory > 3000 GROUP BY T2.CountryCode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.State FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM country WHERE population > 100000 AND language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\" GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE role = \"Director\" GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , COUNT(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT major_record_format FROM orchestra GROUP BY major_record_format ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_ID NOT IN (SELECT orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT DISTINCT T1.grade FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 39502", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 5999", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend WHERE student_id = 55687;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM FRIEND WHERE student_id = 52562;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends AS T1 JOIN likes AS T2 ON T1.student_id = T2.liked_id GROUP BY student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T1.id = T3.student_id WHERE T2.friend_id IN (SELECT T4.student_id FROM friend AS T4 JOIN likes AS T5 ON T4.student_id = T5.student_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T1.id = T3.student_id WHERE T2.student_id IN (SELECT T1.student_id FROM friend AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.student_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2 AND T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2 AND T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(DISTINCT T1.interests) FROM Highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.liked_id JOIN student_id AS T3 ON T2.student_id = T3.id WHERE T3.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners INTERSECT SELECT state FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners WHERE role_code = 'guardian' INTERSECT SELECT state FROM owners WHERE role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.charge_type = \"Medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.treatment_type_code = \"Healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = \"medical\" GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT professional_id , first_name , last_name , home_phone , cell_number FROM Professionals WHERE role_code = \"Veterinarian\" GROUP BY professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , role_code , email_address FROM professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN vets ON T1.professional_id = T2.professional_id GROUP BY T2.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.last_name FROM treatments AS T1 JOIN owners AS T2 ON T1.dog_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.treatment_type_description FROM treatments AS t1 JOIN treatment_types AS t2 ON t1.treatment_type_code = t2.treatment_type_code WHERE t1.charge_type = 'healthcare' ORDER BY sum(t1.charge_amount) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t1.treatment_type_description FROM Treatment_Types AS t1 JOIN treatments AS t2 ON t1.treatment_type_code = t2.treatment_type_code GROUP BY t1.treatment_type_code ORDER BY sum(t2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T3.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_description FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id ORDER BY T1.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id ORDER BY T2.date_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.name , T2.first_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Medical care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Health care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = \"P\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.gender = 'Puppy' AND T2.treatment_type_code = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.professional_id) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"P\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE gender = 'Puppy' AND dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE gender = 'Puppy' IN (SELECT dog_id FROM treatments WHERE charge_type = 'Healthcare' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.first_name != \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM OWNERS WHERE owner_id NOT IN (SELECT owner_id FROM Dogs WHERE gender = 'Puppy')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = 'veterinarian' EXCEPT SELECT count(*) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.gender = 'dog' AND T2.age < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE gender = 'Puppy' ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE gender = 'Puppy' ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM Charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_name , size_description FROM dogs UNION SELECT breed_name , size_description FROM professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer WHERE Citizenship = \"Vocalist\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT count(*) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Citizenship FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Country FROM singer GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_workillions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Country , MAX(Net_Worth_Millions) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT feature_type_name FROM Other_Available_Features WHERE feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T2.property_type_description FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code WHERE T1.vendor_requested_price = 'X'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..5466e66e833967171641b93d8b745ad002e7ef5c --- /dev/null +++ b/infer/qwen/spider_syn/distillm_train_0.6b_4b_spider_adaptive-srkl_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , State FROM musician GROUP BY State", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT name , location FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , highest FROM stadium ORDER BY average LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , highest FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , stadium_id FROM concert GROUP BY stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.year FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T2.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T1.singer_id = T3.singer_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_ID = T2.singer_ID GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.position FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T2.name , T2.position FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T3.name , T3.location FROM concert AS T1 JOIN singer AS T2 ON T1.concert_id = T2.concert_id JOIN stadium AS T3 ON T3.stadium_id = T1.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T3.name , T3.location FROM concert AS T1 JOIN singer AS T2 ON T1.concert_id = T2.concert_id JOIN stadium AS T3 ON T3.stadium_id = T1.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT highest FROM stadium ORDER BY T2.capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT max(weight) FROM Pets WHERE pet_age = \"young\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pet_type FROM Pets GROUP BY pet_type HAVING pet_type = \"domestic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.F = \"F\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet AS T1 JOIN student AS T2 ON T1.StuID = T2.StuID WHERE T2.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT species) FROM animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT name) FROM animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"Kitten\" INTERSECT SELECT DISTINCT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_type = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(age) , max(age) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T3.PetID = T1.PetID WHERE T3.pet_type = \"Miski\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid IN (SELECT petid FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT StuID FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Fname , T2.Sex , T1.StuID FROM Has_pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.Lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age = 3 AND T1.pet_type = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.FullName , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.model WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.modelid WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.Year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id ORDER BY T2.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t1.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.makeid ORDER BY t2.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT count(*) , T1.Continent FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.state FROM cars_data AS t1 JOIN cars_data AS t2 ON t1.id = t2.id WHERE t1.mpg > t2.mpg GROUP BY t1.state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.countryid GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.Accelerate FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model JOIN car_makers AS T3 ON T3.Id = T2.Makeid WHERE T3.FullName = \"Amc hornet sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"F12\" AND model = \"SW\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName LIKE \"%French%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.CountryId WHERE T2.CountryName = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.fullname = \"Ford\" AND T2.model = \"Ford Fusion\" AND T2.countryname = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.make WHERE T1.country ID IN (SELECT countryid FROM countries WHERE continent = 'United States')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT maker , model FROM model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN (SELECT Country FROM countries AS T2 JOIN car_makers AS T3 ON T2.CountryId = T3.Country ) AS T4 ON T4.Country = T1.Country GROUP BY T1.Id HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN (SELECT ContId FROM cars_data GROUP BY ContId HAVING count(*) >= 1) AS T2 ON T1.Country = T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.Continent FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Ford\" GROUP BY T1.Maker HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T2.Horsepower) , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.Model WHERE Cylinders = 3 GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T2.Horsepower) , T1.Maker FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT t1.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.model WHERE t1.make = 'Ford' ORDER BY t1.mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(cedar) FROM cars_data WHERE model = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , Cylinders FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM car_names AS t1 JOIN model_list AS t2 ON t1.model = t2.modelid JOIN car_makers AS t3 ON t2.make = t3.id GROUP BY t2.model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id WHERE T2.fullName = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.modelid WHERE T1.FullName = \"General Motors\" OR T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Id IN (SELECT MakeId FROM cars_data WHERE Weight > 3500)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT horsepower FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(cylinders) FROM cars_data WHERE make = 'volvo' AND accelerate = (SELECT min(accelerate) FROM cars_data WHERE make = 'volvo')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE model = \"Volvo\" AND accelerate = (SELECT min(accelerate) FROM cars_data WHERE model = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(al Accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(al Accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT t1.model FROM car_names AS t1 JOIN cars_data AS t2 ON t1.model = t2.makeid WHERE t2.cylinders = 4 GROUP BY t1.model ORDER BY t2.Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders != 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE make != 'Ford' INTERSECT SELECT makeid , fullname FROM cars_data WHERE cylinders != 2 AND horsepower != 60", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.makeid WHERE T1.maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T1.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T2.maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T2.Continent FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker != \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T1.Continent FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.ContId EXCEPT SELECT T3.CountryName FROM continents AS T3 JOIN countries AS T2 ON T3.ContId = T2.ContId JOIN car_makers AS T1 ON T2.CountryId = T1.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker > 3 UNION SELECT T1.Id , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId GROUP BY T1.id HAVING count(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId WHERE T2.Mileage = \"fiat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM state AS T1 JOIN airlines AS T2 ON T1.StateCode = T2.Abbreviation WHERE T2.Airline = \"JetBlue Airways\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T2.AirportName , T1.Abbreviation FROM airlines AS T1 JOIN airports AS T2 ON T1.Abbreviation = T2.Abbreviation WHERE T1.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirwayName , T1.ShortenedWord FROM airports AS T1 JOIN airlines AS T2 ON T1.AirportCode = T2.AirportCode WHERE T2.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(T1.airportname) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairportcode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.AirportName LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportcode = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN airports AS T2 ON T1.airline = T2.airline WHERE T1.country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , Country FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.abbreviation = T2.sourceairport WHERE T1.airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = 'Aberdeen' AND T1.DestAirport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Aline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.abbreviation = T2.airline WHERE T1.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airline = 'United Airlines' AND T2.city = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ASY Airport' AND T1.Airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abbreviation = \"United\" AND T1.sourceairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"AHD\" AND T1.airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T3.city = 'Aberdeen' AND T1.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen' AND T1.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports GROUP BY city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T2.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.ShortenedWord , T1.StateOfAireway FROM flights AS T1 JOIN (SELECT ShortenedWord , StateOfAireway FROM airports) AS T2 GROUP BY T1.StateOfAireway ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.DestAirport FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.DestAirport ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T2.DestAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T2.SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T2.airline = 'FLY' AND T2.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airwaycode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.airportname = 'APG' INTERSECT SELECT T1.airwaycode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'CVO' EXCEPT SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airliner WHERE T1.Abandoned = 'CVO' EXCEPT SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.Airline = T2.Airliner WHERE T1.Abandoned = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.DestAirport HAVING COUNT(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.airline , T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.sourceairport WHERE T1.Abbreviation = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.airline , T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.abbriation = T2.destairport WHERE T1.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DestAirport , SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , district FROM employee GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop GROUP BY district ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM shop GROUP BY name , district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , LOCATION FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T2.is_full_time = 'Y' ORDER BY T1.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT Name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop ORDER BY manager_name ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE manager_name NOT IN (SELECT DISTINCT manager_name FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID WHERE T1.year_awarded = 2021", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM hiring AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T1.start_from > 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT DISTINCT district FROM shop WHERE number_products < 3000 INTERSECT SELECT DISTINCT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Template_types;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents WHERE document_type = \"Paper\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.template_id , T1.paragraph_text , T1.document_description FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.template_id , T1.paragraph_text , T1.document_description FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_id , T1.paragraph_id , T1.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.paper_id , t1.layout_id , t2.paragraph_text FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.template_id , t2.layout_id , t1.template_details FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id WHERE T3.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Paragraphs GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT template_id FROM documents GROUP BY document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.template_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM documents EXCEPT SELECT document_id FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT id , edition_number , typename FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM Templates WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T1.edition_number , T2.layout_type_name FROM Templates AS T1 JOIN Layouts AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT layout_type , count(*) FROM Ref_Template_Types GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Layouts AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_id GROUP BY t1.template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types WHERE template_type_code = 'layout' GROUP BY template_type_description HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT layout_type_code FROM layout WHERE name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.Other_Details = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.template_type_description , count(*) FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT layout_type , count(*) FROM ...", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.layout_type FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t1.layout_type ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM documents AS T1 JOIN paragraphs AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_id HAVING count(*) = (SELECT count(*) FROM documents AS T1 JOIN paragraphs AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_code FROM Ref_Template_Types EXCEPT SELECT DISTINCT template_type_code FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types EXCEPT SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.document_id WHERE t2.paragraph_text = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.layout_type_name , T2.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.template_type_description , T2.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.layout_type_description , t1.layout_type_name FROM Ref_Template_Types AS t1 JOIN Template_Type_Code AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT T1.template_type_code FROM Ref_Template_Types AS T1 JOIN Paragraphs AS T2 ON T1.template_type_code = T2.document_id WHERE T1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.template_id JOIN Documents AS t3 ON t2.document_id = t3.document_id WHERE t3.document_name = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.template_type_code = t2.template_type_code JOIN Paragraphs AS t3 ON t2.document_id = t3.document_id WHERE t3.paragraph_text -> 'text file'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM paragraphs AS T1 JOIN document_as_t2 AS T2 ON T1.document_id = T2.document_id JOIN Ref_Template_Types AS T3 ON T3.template_type_code = T2.template_type_code WHERE T3.template_type_description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT paragraph_text FROM Paragraphs WHERE document_id IN (SELECT id FROM Documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT t2.paragraph_text FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT count(*) , T1.document_id , T2.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.template_id , T1.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T2.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text = 'Brazil' UNION SELECT document_id FROM paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Brazil' INTERSECT SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT count(*) , Hometown FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teach_ID = T2.Technical_ID GROUP BY T2.Hometown ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Course_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T1.Name , T2.Course_ID FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T1.Name , T1.Name FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T2.Course_ID = T3.Course_ID ORDER BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T3.Course_ID = T1.Course_ID WHERE T3.Curriculum = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 35 AND Grade = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_OF_MEMBERSHIP FROM visitor WHERE LEVEL_OF_MEMBERSHIP > 4 ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT Open_Year , Num_of_Staff FROM museum WHERE Name = \"Plaza Museum\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id GROUP BY T1.visitor_id ORDER BY sum(T1.total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT T2.Total_spent FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN ( SELECT T2.visitor_id FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id WHERE T1.Open_Year > 2010 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches WHERE draw_size = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_name = \"Tournament\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_name = \"T1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_name WHERE YEAR = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_name WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , state_abbr FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id GROUP BY T2.country_code ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.state_code FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open tourney\" ORDER BY T2.winner_rank LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.loser_name , T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.loser_name ORDER BY max(T1.minutes) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T1.ranking_date , T1.ranking_points FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM players GROUP BY state_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.state FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.round ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , COUNT(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T2.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.first_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code , T2.birth_date FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id ORDER BY ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(killed) , min(killed) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T2.disposition_of_ship , T1.note FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T1.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.bulgarian_commander WHERE T1.ship_type = 'Brig' EXCEPT SELECT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.bulgarian_commander WHERE T1.ship_type != 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT T1.id FROM ship AS T1 JOIN battle AS T2 ON T1.lost_in_battle = T2.id WHERE T1.tonnage = 225 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM addresses WHERE line_1 = 'line 1' INTERSECT SELECT address_id FROM addresses WHERE line_2 = 'line 2'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_type = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = \"Port\" AND line_2 = \"Chelsea\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T2.department_id FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T2.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id WHERE T2.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = \"Engineering\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT T1.section_name , T1.section_description FROM Sections AS T1 JOIN Courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T2.section_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T2.section_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.semester_name , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Semesters AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T1.student_id = T3.student_id GROUP BY T1.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT T2.department_description FROM courses AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id WHERE T1.course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id JOIN semester_id AS T4 ON T2.semester_id = T4.semester_id WHERE T3.degree_summary_name = \"2nd Degree Program\" GROUP BY T1.student_id HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Undergrad' INTERSECT SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor\\'\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT degree_program_id FROM student_enrolment GROUP BY degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment_degree_programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T2.student_enrolment_id , count(*) FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_enrolment_id GROUP BY T2.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.student_id NOT IN (SELECT T3.student_id FROM students AS T3 JOIN student_enrolment AS T4 ON T3.student_id = T4.student_id GROUP BY T3.student_id HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id JOIN Student_Enrolment_Courses AS T3 ON T2.course_id = T3.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id JOIN student_enrolment AS T3 ON T3.student_id = T2.student_id JOIN degree_programs AS T4 ON T4.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id JOIN student_enrolment AS T3 ON T3.student_id = T2.student_id JOIN degree_programs AS T4 ON T4.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.transcript_id = T2.transcript_id JOIN Student_Enrolment AS T3 ON T2.student_course_id = T3.student_course_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.transcript_id = T2.transcript_id JOIN Student_Enrolment AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id JOIN Student_Enrolment_Courses AS T4 ON T2.course_id = T4.course_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_enrolment_id WHERE T2.transcript_date = (SELECT max(transcript_date) FROM transcripts)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_id ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE student_id NOT IN (SELECT student_id FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , count(*) FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM Transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , other_student_details FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , \"transcript date\" FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(T1.date_left) FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.course_id FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.transcript_id = T2.transcript_id JOIN Student_Enrolment AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Transcript_Contents AS T2 ON T1.transcript_id = T2.transcript_id JOIN Student_Enrolment_Courses AS T3 ON T1.student_course_id = T3.student_course_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = \"Master\" INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = \"Bachelor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = \"Masters\" INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T2.address_id) FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T2.line_1 FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM Students ORDER BY first_name , last_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM STUDENTS ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" UNION SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" AND T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name , last_name FROM students WHERE cell_mobile_number = 09700166582 OR permanent_address_id IN (SELECT address_id FROM addresses WHERE country = \"Haiti\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT Written_by FROM Cartoon WHERE Directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT T2.title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\" OR T1.directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM tv_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name , content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'en'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM tv_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t2.series_name FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.series_name FROM TV_series AS t1 JOIN cartoon AS t2 ON t1.channel = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT * FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Episode FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.channel WHERE T1.title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Weekly_Rank FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.channel WHERE T1.title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.channel FROM TV_channel AS T1 JOIN tv_series AS T2 ON T1.id = T2.channel WHERE T2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t1.series_name FROM cartoon AS t1 JOIN tv_series AS t2 ON t1.channel = t2.channel WHERE t2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT Directed_by , count(*) FROM cartoon GROUP BY Directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM tv_channel WHERE content = \"HD TV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , TV_Channel.id FROM TV_Channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "{\"sql\": \"SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \\\"\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Todd\" AND T1.write_by = \"Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel JOIN tv_series AS t3 ON t3.id = t2.18_49_Rating_Share WHERE t2.directed_by = \"Todd\" AND t2.written_by = \"Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT state FROM cartoon EXCEPT SELECT state FROM cartoon WHERE written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.Channel FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.Channel FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T2.Series_Name , T2.Country FROM cartoon AS T1 JOIN TV_Channel AS T2 ON T1.Channel = T2.id WHERE T1.directed_by = \"Ben Jones\" INTERSECT SELECT T2.Series_Name , T2.Country FROM cartoon AS T1 JOIN TV_Channel AS T2 ON T1.Channel = T2.id WHERE T1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel WHERE country = 'USA' GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel WHERE id NOT IN (SELECT channel FROM cartoon AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM cartoon EXCEPT SELECT channel FROM cartoon AS T1 JOIN Cartoon AS T2 ON T1.channel = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM tv_channel EXCEPT SELECT tv_channel.package_option FROM tv_channel JOIN cartoon ON tv_channel.id = cartoon.channel WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE id NOT IN (SELECT Channel FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE nationality = \"Chinese\" AND birth_date < \"2000-01-01\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE Nationality = \"China\" AND Birth_Date < \"2023-12-31\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID = (SELECT People_ID FROM people WHERE Nationality = \"Chinese\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID = (SELECT People_ID FROM people WHERE Nationality = \"Chinese\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT money_rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Nationality = \"Gamers\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Nationality = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Earnings = \"Car Gamers\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Earnings = \"car gamer\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS EXCEPT SELECT contestant_name FROM CONTESTANTS WHERE contestant_name = 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT state , created FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T1.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.area_code , T1.state FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state GROUP BY T1.state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.set_up_date , T1.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = (SELECT T3.contestant_number FROM CONTESTANTS AS T3 WHERE T3.contestant_name = 'Tabatha Gehling') INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = (SELECT T3.contestant_number FROM CONTESTANTS AS T3 WHERE T3.contestant_name = 'Kelly Clauss')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t1.SurfaceArea) FROM country AS t1 JOIN country AS t2 ON t1.Code = t2.Code WHERE t1.Continent = \"Caribbean\" AND t2.name = \"State\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE name = 'Continental' AND continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"ANGUILLA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"ANGUILLA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT district FROM city WHERE population = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.Population , T1.LifeExpectancy FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code WHERE T2.CountryCode = \"BR\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , count(*) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Angola\" GROUP BY T2.Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(people) , name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE t2.continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(tp.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(T1.LiveExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.code = T2.code WHERE T1.region = \"Republic\" AND T2.name = \"African\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(t1.lifeexpectancy) FROM country AS t1 JOIN country AS t2 ON t1.code = t2.code WHERE t1.continent = \"Africa\" AND t2.region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE governmentform = 'Union'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(population) FROM country WHERE region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = \"ARUBA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode = (SELECT code FROM city WHERE name = 'Aruba' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Afghanistan\" AND T1.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.State FROM city AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY SUM(T2.Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Continent FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE Language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.StateName FROM city AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.StateName FROM city AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t1.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.region FROM countrylanguage AS T1 JOIN city AS T2 ON T1.countrycode = T2.code2 WHERE T1.language = \"English\" OR T1.language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.language = 'Dutch' OR T1.language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = \"Republic\" GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = \"Republic\" GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode JOIN country AS T3 ON T2.language = 'English' GROUP BY T2.countrycode ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code WHERE T1.continent = \"Asia\" ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.Population , T1.LifeExpectancy FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" ORDER BY T1.Population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = \"N\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = \"N\" AND T1.Name != \"India\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode EXCEPT SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T2.Language) FROM city AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.population < 1000000 AND T2.IsOfficial = 1 AND T2.year < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE independyyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT min(population) FROM country AS T1 JOIN country AS T2 ON T1.code = T2.code WHERE T1.continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent != \"Asia\" GROUP BY name HAVING sum(population) < (SELECT sum(population) FROM country WHERE continent != \"Asia\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE language != 'en'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT state FROM state WHERE state NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.nationabbrev FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode EXCEPT SELECT T1.nationabbrev FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.nationcode FROM countrycountry AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode EXCEPT SELECT T1.nationcode FROM countrycountry AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country WHERE governmentform != 'Republic' AND (language != 'en' OR isofficial != 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT abbr FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode EXCEPT SELECT T1.abbr FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.abbr FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 1 EXCEPT SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" AND T2.IsOfficial = \"Yes\" EXCEPT SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" AND T2.IsOfficial = \"Yes\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.continent = \"Asia\" AND T2.isofficial = 1 AND T2.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode JOIN country AS T3 ON T2.countrycode = T3.code WHERE T3.name = 'China' AND T3.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.IndepYear , T2.Continent FROM country AS T1 JOIN country AS T2 ON T1.code = T2.code ORDER BY T1.population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.indepyear , T1.Continent FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code ORDER BY T1.population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT capital , name FROM country ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.population , t1.headofstate FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code WHERE t2.population = (SELECT max(population) FROM city)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT T1.GovernmentForm , COUNT(*) , avg(T2.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.GovernmentForm = T2.GovernmentForm WHERE avg(T2.LifeExpectancy) > 72 GROUP BY T1.GovernmentForm", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT governmentform , sum(population) FROM city WHERE lifeexpectancy > 72 GROUP BY governmentform", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) , continent FROM country GROUP BY continent HAVING avg(lifeexpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT T1.Continent , sum(T2.Population) , avg(T2.LifeExpectancy) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code WHERE T1.LifeExpectancy < 72 GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , region FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" AND T2.Population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(T1.population) , avg(T1.surfacearea) FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.continent = \"North America\" AND T2.surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage ORDER BY Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T2.Language , T1.State FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.nationabbr , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode GROUP BY T2.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Percentage) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.StateCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor EXCEPT SELECT name FROM conductor WHERE nationality = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor WHERE year_of_work = (SELECT max(year_of_work) FROM conductor) ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.Name , T1.Orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID JOIN performance AS T3 ON T2.Orchestra_ID = T3.Orchestra_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T1.Record_Company ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT Major_record_format FROM orchestra GROUP BY Major_record_format ORDER BY count(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra != 'Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.year_of_founded < 2003 INTERSECT SELECT T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.year_of_founded HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "{\"sql\": \"SELECT grade FROM highschooler WHERE id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM friend WHERE friend_id = (SELECT id FROM", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT T1.id , count(*) FROM friends AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(DISTINCT friend_id) FROM FRIEND", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.ID = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT count(*) , T1.name FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T1.student_id = 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 59568", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler EXCEPT SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friend INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friend INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T2.student_id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T3.student_id = T2.student_id WHERE T2.friend_id IN (SELECT T1.id FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.friend_id HAVING count(*) = 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT count(*) , T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.ID WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.ID = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = \"guardian\" INTERSECT SELECT state FROM Professionals WHERE role_code = \"veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = \"dog guardian\" INTERSECT SELECT state FROM Professionals WHERE role_code = \"dog veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.charge_type = \"Medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T1.owner_id , T1.first_name , T1.last_name , T1.cell_number FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM OWNERS AS T1 JOIN PROFESSIONALS AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T1.owner_id , T1.last_name , T1.cell_number FROM OWNERS AS T1 JOIN PROFESSIONALS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = \"Veterinarian\" GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"Veterinarians\" EXCEPT SELECT first_name FROM Professionals WHERE role_code = \"Dog Name\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"Veterinarians\" EXCEPT SELECT first_name FROM Professionals WHERE role_code = \"Dog names\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.owner_id FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM Dogs AS T1 JOIN Breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id ORDER BY T3.cost_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T3.dog_id = T2.dog_id ORDER BY T3.cost_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code JOIN treatments AS T3 ON T2.dog_id = T3.dog_id WHERE T3.cost_of_treatment = (SELECT min(cost_of_treatment) FROM treatments) AND T3.charge_type = 'health-care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code JOIN Treatment_Types AS T3 ON T3.treatment_type_code = T2.dog_id GROUP BY T1.breed_name ORDER BY sum(T3.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.cell_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM charges)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = \"Veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_birth , T2.first_name FROM Dogs AS T1 JOIN Professionals AS T2 ON T1.dog_id = T3.professional_id JOIN Treatment_Types AS T3 ON T2.role_code = T3.treatment_type_code WHERE T3.date_of_treatment = (SELECT date_of_treatment FROM treatments WHERE cost_of_treatment = 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.charge_amount , T2.treatment_type_description FROM charges AS T1 JOIN Treatment_Types AS T2 ON T1.charge_type = T2.treatment_type_code WHERE T1.charge_type = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments WHERE treatment_type_code = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.size_description FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T1.size_code = T3.size_code WHERE T1.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.weight FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id JOIN Sizes AS T3 ON T1.size_code = T3.size_code WHERE T1.age > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.breed_name , T2.name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN puppies AS T3 ON T2.dog_id = T3.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id JOIN Breeds AS T3 ON T1.breed_code = T3.breed_code WHERE T3.breed_name = \"Rare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T5.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id JOIN Professionals AS T3 ON T2.professional_id = T3.professional_id JOIN Treatment_Types AS T4 ON T3.treatment_type_code = T4.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.name , T1.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Medical Care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'Health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \"M\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = 'Health Care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.professional_id) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.gender = 'P puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments WHERE treatment_type_code = \"Puppy Care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE \"%West%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM treatments WHERE date_of_treatment = (SELECT date_of_birth FROM dogs ORDER BY date_of_birth DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.date_of_treatment LIKE \"%health-care%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = \"Guardian\" EXCEPT SELECT count(*) FROM dogs WHERE gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.first_name != \"guardian\" OR T2.gender != \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T1.dog_id = T3.dog_id AND T2.treatment_type_code = \"Puppy care\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = \"Puppy\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = \"P puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs WHERE gender = 'M' AND breed_code = 'Pipino'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_type DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM Professionals WHERE role_code = 'Veterinary'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code JOIN Sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.age = \" puppy \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code WHERE T1.role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT COUNT(*) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT DISTINCT t1.title FROM song AS t1 JOIN singer AS t2 ON t1.singer_id = t2.singer_id GROUP BY t2.citizenship ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT country FROM singer GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth Millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(networth Millions) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT country FROM singer INTERSECT SELECT country FROM singer WHERE birth_year < 1945 INTERSECT SELECT country FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Property_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT t2.feature_type_name FROM other_available_features AS t1 JOIN ref_feature_types AS t2 ON t1.feature_type_code = t2.feature_type_code WHERE t1.feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT property_type_description FROM Ref_Property_Types WHERE property_type_code = (SELECT property_type_code FROM Properties GROUP BY property_type_code HAVING count(*) = 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT T1.property_name FROM properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code WHERE T2.property_type_code = 'house' UNION SELECT T1.property_name FROM properties AS T1 JOIN Other_Property_Features AS T2 ON T1.property_id = T2.property_id JOIN Other_Available_Features AS T3 ON T2.feature_id = T3.feature_id WHERE T3.apt_feature_3 > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..f12c09bbf9d061b762dfd336940e9455fcd52ee7 --- /dev/null +++ b/infer/qwen/spider_syn/fdd_train_0.6b_4b_spider_sfkl_t33-36_s25-28_e5-bs2-lr0.0001-G8-N2-NN1-kd0.7-lora-16-64-0.1__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer WHERE is_male = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT T2.name , T2.song_release_year FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.singer_id = T2.singer_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT T1.name , T1.song_release_year FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.singer_id = T2.singer_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , Country FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT T1.song_name FROM singer AS T1 JOIN concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id HAVING avg(T1.age) > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T2.stadium_id = T1.stadium_id WHERE T1.capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT T1.Location , T1.Name FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T2.Capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT avg(Average) , name FROM stadium GROUP BY average ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT avg(Average) , name FROM stadium GROUP BY average ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR >= 2014 GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.concentor_id , T2.concentor_id , T1.date FROM concert AS T1 JOIN singer_in_concentor AS T2 ON T1.concentor_id = T2.concentor_id GROUP BY T1.concentor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.name , T1.theme , count(*) FROM singer_in_concent T1 JOIN singer T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.name , T2.theme , count(*) FROM concert AS T1 JOIN singer_in_concent AS T2 ON T1.concent_id = T2.concent_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concent AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concent T1 JOIN singer T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.Name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Country = \"United States\" AND T1.Song_release_year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.Name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Song_release_year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T2.Name , T2.Country FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Song_Name = \"Hey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN singer_in_concent as T2 ON T1.singer_id = T2.singer_id WHERE T2.song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Has_pet WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Has_pet WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT T2.weight FROM Has_pod AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T1.stuid = (SELECT stuid FROM Has_pup as T3 GROUP BY stuid ORDER BY age LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT sum(weight) FROM Has_pod AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T2.pemid = 1 AND T1.age = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pet_type FROM Has_pet GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pet_type , count(*) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid GROUP BY T1.petid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pem AS T1 JOIN Student AS T2 ON T1.stuid = T2.stuid WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pem AS T1 JOIN Student AS T2 ON T1.stuid = T2.stuid WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_puples AS T1 JOIN Student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = \"F\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_ppet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Has_pemet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pet_type) FROM Has_pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T2.Fname , T2.Lname FROM Has_pet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid WHERE T1.petid = 'kittens' OR T1.petid = 'pupus'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petID = T3.petID WHERE T3.pettype = 'kittens' OR T3.pettype = 'poodle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T2.fname , T2.lname FROM Has_pemet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T1.stuid = T3.stuid WHERE T2.pettype = 'kitten' INTERSECT SELECT T2.fname , T2.lname FROM has_pemet AS T1 JOIN pets AS T2 ON T1.petid = T2.petid JOIN student AS T3 ON T1.stuid = T3.stuid WHERE T2.pettype = 'puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petID = T3.petID WHERE T3.pettype = 'Pug' AND T3.petage = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'Kittens'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T2.lname , T2.fname , T2.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid EXCEPT SELECT T2.lname , T2.fname , T2.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_pet WHERE petID = 'kittens'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE petID = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_pod AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petID = T3.petID WHERE T3.pettype = 'pug' AND T3.weight > 1 WHERE T3.pettype != 'cat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid = 2 AND T1.fname != \"Kittens\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT T2.pet_type , T2.weight , T1.age FROM Has_pem_test AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , sum(weight) FROM Has_pemus AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid GROUP BY T1.petid ORDER BY T1.pettype LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT StuID , weight FROM Has_pem WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT StuID , weight FROM Has_pem WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(T1.pet_age) , max(T1.pet_age) , T2.pet_type FROM Has_pem AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid GROUP BY T2.pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(T2.pemtage) , max(T2.pemtage) , T1.pemttype FROM Has_pemt AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid GROUP BY T1.pemttype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "{\"sql\": \"SELECT avg(weight) , pet_type FROM Has_pem WHERE pet_type = \\\"Labrador \\udent\\ enough to be a cat\\\"\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(weight) , pet_type FROM Has_pet GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.lname , T2.age FROM Has_pet AS T1 JOIN student AS T2 ON T1.stuID = T2.stuID JOIN pets AS T3 ON T1.petID = T3.petID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT StuID FROM Has_pem AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid JOIN Student AS T3 ON T1.stuid = T3.stuid WHERE T3.lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM has_pet WHERE LName = 'Smith')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , T1.Fname , T1.Lname FROM Has_pem AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.lname , T1.sex FROM Student AS T1 JOIN Has_pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.stuid HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.lname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.lname FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T2.pemid = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.lname FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T2.ppetage = 3 AND T1.stuid = T2.stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(T2.age) FROM Student AS T1 JOIN Has_pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT avg(age) FROM Student AS T1 JOIN Has_pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM countries WHERE countryname LIKE '%Europe%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT continent_id , continent_name , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1 Continent = T2.Cont_id GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT continent_id , country_name , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1 Continent = T2.Contid GROUP BY T1.CountryName", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries WHERE countryname = \"States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT maker , COUNT(*) , fullname FROM car_makers GROUP BY fullname", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT maker , maker_name , count(*) FROM car_makers GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN cars_data AS T3 ON T3.Id = T2.Model ORDER BY T3.Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT maker FROM car_makers WHERE country = 'United States' AND YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT maker FROM car_makers WHERE country = 'United States' AND year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT maker , MIN(year) FROM cars_data GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T1.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_makers AS T3 ON T2.Model = T3.Model WHERE T3.Maker = \"Ford\" AND T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE YEAR > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT continent , count(*) FROM country AS T1 JOIN continents AS T2 ON T1 Continent = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT continent , count(*) FROM countries AS t1 JOIN continents AS t2 ON t1.Continent = t2.Continent GROUP BY t1.CountryName", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country_name FROM car_makers GROUP BY country_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.FFullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId GROUP BY T1.FFullName", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FFullName FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT Accelerate FROM cars_data WHERE YEAR = 2014 AND Maker = \"Amc Hornet\" AND MAKE = \"Softhornet\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE country = 'United States' AND maker = 'Ford' AND model = 'Amc Hornet'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid JOIN countryname AS T3 ON T1.countryname = T3.countryname WHERE T3.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM cars_data WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country_id = T2.country_id JOIN continent AS T3 ON T2 Continent = T3.ContId WHERE T2.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MGPH) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MGPE) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT T1.MGGE FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN car_makers AS T3 ON T2.Model = T3.Model WHERE T3.Maker = \"Ford\" AND T1.Year = 1974 GROUP BY T1.Cylinders ORDER BY T1.MGGE LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND Cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT maker , model FROM car_makers", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT maker , model FROM car_makers JOIN car_names ON car_makers.id = car_names.makeid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT country_name , id FROM car_makers GROUP BY country_name HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.countryname , T1.id FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.countryid GROUP BY T1.countryname HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(Weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(Weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT countryname FROM countries WHERE continent = \"Europe\" GROUP BY countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM country AS T1 JOIN country_list AS T2 ON T1.CountryId = T2.CountryId WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(power) , maker FROM cars_data WHERE cylinders = 3 GROUP BY maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T3.MGPA) , T2.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model JOIN cars_data AS T3 ON T3.Id = T2.Id WHERE T1.Maker = \"Ford\" AND T1.MaxCylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model JOIN car_names AS T3 ON T1.MakeId = T3.MakeId WHERE T3.Make = \"Ford\" ORDER BY T2.MGAP DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T3.Model = T2.Model ORDER BY T1.MGPL DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE maker = \"VOLVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(acceleration) , count(*) FROM cars_data WHERE cylinders = \"2\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) FROM cars_data WHERE cylinders = \"1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT maker FROM car_makers GROUP BY maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeId JOIN cars_data AS T3 ON T3.id = T2.model WHERE T1.FULL_NAME = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN cars_data AS T3 ON T3.id = T2.model WHERE T1.maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , fullname FROM car_makers WHERE country_id = (SELECT country_id FROM car_makers GROUP BY country_id HAVING count(*) > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , id FROM car_makers GROUP BY maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE country = 'United States' AND weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN cars_data AS T3 ON T3.id = T2.model WHERE T3.Weight > 3500 INTERSECT SELECT DISTINCT maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid JOIN cars_data AS T3 ON T3.id = T2.model", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE WEIGHT BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT count(DISTINCT YEAR) FROM cars_data WHERE weight < 4000 INTERSECT SELECT count(DISTINCT YEAR) FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT accelerate FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT accelerate FROM cars_data ORDER BY accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(accelerate) , id FROM cars_data WHERE cylinder_count = 1 GROUP BY id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT count(*) , MIN(acceleration) FROM cars_data WHERE model_list.Model = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE acceleration > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE acceleration > (SELECT max(acceleration) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker != \"Ford\" AND maker != \"Ford\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker != \"Ford\" AND maker != \"Ford\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.id JOIN car_names AS T3 ON T2.id = T3.id WHERE T3.Make = \"Ford\" AND T1.Cylinders = 4 GROUP BY T1.model ORDER BY T3.Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model GROUP BY T1.Model ORDER BY COUNT(*) DESC LIMIT 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT maker , maker_name FROM car_makers WHERE country_id = (SELECT country_id FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE count_cylinders = 3) )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT maker , COUNT(*) FROM car_makers WHERE country != \"United States\" AND id NOT IN (SELECT id FROM cars_data WHERE cylinders < 4) GROUP BY maker ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MGPS) , YEAR FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MGPS) , id FROM cars_data WHERE cylinders = 8 OR year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE weight < 3500 AND maker != 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT maker FROM car_makers WHERE weight < 3500 AND maker != \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT countryid FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT countryid FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , maker FROM car_makers WHERE id >= 2 GROUP BY maker HAVING count(*) >= 2 INTERSECT SELECT maker FROM car_makers WHERE id >= 3 GROUP BY maker HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker , COUNT(*) FROM car_makers WHERE maker = (SELECT maker FROM car_makers GROUP BY maker HAVING COUNT(*) >= 2) INTERSECT SELECT maker FROM car_makers GROUP BY maker HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT id , countryname FROM car_makers WHERE maker = 'Ford' OR maker = 'Ford' AND country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT id , maker FROM car_makers WHERE countryId = countries.countryName INTERSECT SELECT id , maker FROM car_makers WHERE countryId = countries.countryName GROUP BY maker HAVING count(*) > 3 OR maker = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T2.Country FROM airlines AS T1 JOIN airports AS T2 ON T1.AirportCode = T2.AirportCode JOIN flights AS T3 ON T1.FlightNo = T3.FlightNo WHERE T1.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.country FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.airline WHERE T2.FlightNo = 'JETBLU'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"JETBLUE Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.SourceAirport = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , airportcode FROM airports WHERE country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , airportcode FROM airports WHERE country = 'USA' AND airportcode = 'IATA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(flightno) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.sourceairport LIKE 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.sourceairport = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT T1.city , T1.country FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.FlightNo = 'Alton Airport'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT T2.City , T2.Country FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'Alton'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE FlightNo = \"ATOL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'ATA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"Airport Cembarded (ABER)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"Aberport Airports Inc.\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports WHERE airportname = \"Aberdeen\" INTERSECT SELECT count(*) FROM flights WHERE sourceairport = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberona'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = \"Aberdeen\" AND sourceairport = \"Aberdeen\" AND destairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'Abberon' AND T2.AirportName = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'ASY' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'United Airlines' AND FlightNo = 'ASY Airport'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airleightname = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'United Airlines' AND FlightNo = 'AHD-112'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'Aberdeen' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights WHERE airline = 'United Airlines' AND sourceairport = 'Aberona'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.city FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.id WHERE T3.country = 'United States' GROUP BY T2.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode GROUP BY T1.SourceAirport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.sourceairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.airportcode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode , T2.country FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportname , T2.airline FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.airportname ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T2.airportname FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T1.airline = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.terminalairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T1.city = T3.city WHERE T3.country = 'APG' INTERSECT SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport AND T3.country = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T1.airportcode = T3.airportcode WHERE T2.airline = 'APG' INTERSECT SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T2.airline = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.sourceairport = 'CVO' EXCEPT SELECT DISTINCT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.departure_airline = 'CVO' EXCEPT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.departure_airline = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T2.airportname FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.sourceairport HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T2.airportname FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.sourceairport HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T2.airportname FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode GROUP BY T1.sourceairport HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE AirportCode = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE AirportCode = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T2.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberport\" AND DestAirport = \"Aberport\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T2.FlightCode FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Abberle\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports WHERE airportname = 'Aberport' OR airportname = 'Abilene'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T1.district FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.district ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , city , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , city , district FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id JOIN employee AS T3 ON T2.employee_id = T3.employee_id GROUP BY T1.employee_id ORDER BY T1.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T2.bonus = (SELECT max(bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT manager_name FROM employee EXCEPT SELECT employee_id FROM evaluation", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM hiring AS t1 JOIN employee AS t2 ON t1.employee_id = t2.employee_id JOIN shop AS t3 ON t1.shop_id = t3.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T1.name FROM hiring AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID JOIN shop AS T3 ON T1.Shop_ID = T3.Shop_ID GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T1.name FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id JOIN shop AS T3 ON T3.shop_id = T2.shop_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID GROUP BY T1.Employee_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT T1.name , T2.start_from , T2.Is_full_time FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , other_details FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , document_id FROM documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT t1.document_name , t2.layout_id FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id WHERE t2.document_details LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.paper_id , t2.layout_id , t2.description FROM documents AS t1 JOIN templates AS t2 ON t1.template_id = t2.template_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT T1.paper_id , T2.layout_id , T2.description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM templates WHERE template_type_code = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id JOIN Ref_template_types AS T3 ON T2.template_type_code = T3.template_type_code WHERE T3.template_type_description = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT T1.Layout_ID , count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Layout_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T2.type FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T2.type ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.type FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id GROUP BY T2.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.id FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id JOIN paragraphs AS T3 ON T2.document_id = T3.document_id GROUP BY T2.document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.Template_ID FROM templates AS T1 JOIN documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT t1.template_id FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code NOT IN (SELECT template_type_code FROM templates)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.id , T2.version_number , T3.type_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id JOIN Ref_template_types AS T3 ON T1.template_type_code = T3.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.layout_type FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id JOIN ref_template_types AS t3 ON t1.template_type_code = t3.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT document_id FROM documents WHERE template_id IN (SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT DISTINCT T1.layout_id FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id JOIN ref_template_types AS T3 ON T1.template_type_code = T3.template_type_code WHERE T3.template_type_description = \"PP\" OR T3.template_type_description = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM templates AS T1 JOIN ref_template_types AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T2.edition_number , T2.layout_type FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id WHERE T1.version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T2.Edition_Number , T1.Layout_Type_Name FROM Templates AS T1 JOIN Ref_template_types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.Version_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT T1.layout_type , count(*) FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Template_Type_Description FROM templates AS T1 JOIN ref_template_types AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT t1.template_type_code FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT T1.template_type_description FROM Ref_template_types AS T1 JOIN templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , T1.Layout_Type_Code FROM templates AS T1 JOIN ref_template_types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.Layout_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(edition_number) , T1.layout_type_code FROM templates AS T1 JOIN ref_template_types AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.layout_type_code FROM templates AS T1 JOIN layouts AS T2 ON T1.template_id = T2.template_id WHERE T2.layout_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.layout_type_code FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id JOIN ref_template_types AS T3 ON T1.template_type_code = T3.template_type_code WHERE T2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT DISTINCT document_name FROM Documents WHERE template_id IN (SELECT template_id FROM templates WHERE template_type_code = \"BK\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id JOIN Ref_template_types AS T3 ON T2.template_type_code = T3.template_type_code WHERE T3.template_type_description = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T2.layout_type_count , T1.layout_type_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.layout_type_count", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT DISTINCT layout_type , count(*) FROM templates GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.layout_type FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id JOIN ref_template_types AS T3 ON T1.template_type_code = T3.template_type_code GROUP BY T1.layout_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_type_code FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id WHERE document_type_code = \"text\" GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT layout_type FROM templates EXCEPT SELECT DISTINCT layout_type FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code EXCEPT SELECT t1.template_type_description FROM ref_template_types AS t1 JOIN documents AS t2 ON t1.template_type_code = t2.template_type_code JOIN paragraphs AS t3 ON t2.document_id = t3.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT t2.template_details , t1.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T2.type_name , T2.description FROM templates AS T1 JOIN ref_template_types AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t2.layout_type FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id JOIN ref_template_types AS t3 ON t1.template_type_code = t3.template_type_code WHERE t1.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.description FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.layout_type_name FROM ref_template_types AS t1 JOIN templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT T1.template_type_code FROM Ref_template_types AS T1 JOIN templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_details = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.layout_type_description FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id JOIN ref_template_types AS t3 ON t1.template_type_code = t3.template_type_code WHERE t2.document_name = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.other_details FROM templates AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id JOIN paragraphs AS t3 ON t2.document_id = t3.document_id WHERE t3.paragraph_text != \"\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.layout_id FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id JOIN Ref_template_types AS T3 ON T1.template_type_code = T3.template_type_code WHERE T3.template_type_description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T2.Template_ID FROM templates AS T1 JOIN documents AS T2 ON T1.Template_ID = T2.Template_ID JOIN ref_template_types AS T3 ON T1.Template_Type_Code = T3.Template_Type_Code WHERE T1.Template_Details = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.Other_Details = \"Korea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT t2.Other_Details FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Korea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT DISTINCT T2.Paragraph_ID , T2.Paragraph_Text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T1.Document_Name = \"Welcome to NY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T2.paragraph_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Welcome to NY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT t2.paragraph_text FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT t2.paragraph_text FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT T1.paper_id , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paper_id ORDER BY T1.paper_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT count(*) , t1.id FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t1.id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.document_id , T2.Paragraph_Text , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.document_id , T2.Paragraph_Text , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.Paragraph_ID FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID GROUP BY T2.Document_ID ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT T2.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T2.document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.paper_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Brazil' INTERSECT SELECT T1.paper_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = \"Brazil\" INTERSECT SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = \"Ireland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT name FROM teacher ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT name FROM teacher WHERE hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT name FROM teacher WHERE age = 32 OR age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT name FROM teacher WHERE age = 32 OR age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T1.Grade LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT T1.Hometown FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T1.Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T1.name , T2.course FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T1.name ORDER BY T2.grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.name , T1.name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T1.teacher_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T1.name , T2.curriculum FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.teacher_id = T2.teacher_id ORDER BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T1.name FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.teacher_id = T2.teacher_id JOIN course AS T3 ON T2.course_id = T3.course_id WHERE T3.course = 'math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT name FROM teacher WHERE grade = 'math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.name , count(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T1.name , count(*) FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T1.Name FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT name FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T1.teacher_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE level_of_membership > 4 ORDER BY level_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(Age) FROM visitor WHERE Level_of_membership < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , level_of_membership FROM visitor WHERE level_of_membership > 4 ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum GROUP BY museum_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = \"Pl Plaza Museum\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T1.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T1.name , T2.level_of_membership FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID JOIN visitor AS T3 ON T1.visitor_ID = T3.ID WHERE T3.level_of_membership = \"VIP\" ORDER BY T1.Total_spent DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM visit GROUP BY museum_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum EXCEPT SELECT T2.name FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.Name , T2.Age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(T2.Num_of_Ticket) , max(T2.Num_of_Ticket) FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID JOIN visitor AS T3 ON T1.visitor_ID = T3.ID WHERE T3.Level_of_membership = 'Visitor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_spent) FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id WHERE T2.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id WHERE T2.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id WHERE T2.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE ID NOT IN (SELECT visitor_ID FROM visit WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT T2.first_name , T2.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T1.country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT birth_date , first_name FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(win_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(win_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches ORDER BY loser_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_id HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tournament_name FROM matches GROUP BY tournament_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.year = 2013 INTERSECT SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.wider_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_id = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_id = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.match_num = 2 AND T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.state_abbr FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.round = (SELECT max( T2.round ) FROM matches AS T2 WHERE T2.round = T2.round)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.round = (SELECT max(1) FROM matches)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T1.birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.round = 1 AND T2.left = 'left' AND T2.birth_date = '1990' ORDER BY T2.birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.tourney_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T2.rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open tourney\" ORDER BY T2.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" GROUP BY T1.name ORDER BY sum(T2.rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T2.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY match_num DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking_points) , T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.first_name , T1.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , avg(T2.ranking) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.first_name , T1.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(ranking_points) , T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.first_name , T1.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , T1.last_name , sum(T2.rankings_points) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.first_name , T1.last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , T1.state FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , COUNT(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT sum(ranking_points) , T1.ranking FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.ranking_ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , COUNT(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.name , T1.rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.round , T2.match_num LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.name , T1.rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.round , T2.match_num LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT winner_id) FROM matches WHERE tourney_name = \"WTA Championships\" INTERSECT SELECT count(DISTINCT winner_id) FROM matches WHERE hand = \"Left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T1.hand = \"Left\" AND T2.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY T2.rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(deaths) , min(deaths) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT injured , count(*) FROM death GROUP BY injured ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT injured FROM death WHERE cause_of_ship_id = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.debate_id WHERE T2.leet_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT cast( t1.id AS char) , t1.name FROM ship AS t1 JOIN death AS t2 ON t1.id = t2.caused_by_ship_id GROUP BY t2.caused_by_ship_id HAVING sum( deaths ) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.id WHERE T1.latron_commander = 'Baldwin I' INTERSECT SELECT DISTINCT T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.id WHERE T1.bulgarian_commander = 'Kaloyan'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE id NOT IN (SELECT ship.id FROM ship AS T1 JOIN ship AS T2 ON T1.id = T2.id WHERE T1.tonnage = 225)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T2.date FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.battle_id WHERE T1.name = 'Littice' INTERSECT SELECT T1.name , T2.date FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.battle_id WHERE T1.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != (SELECT cast( name AS text) FROM ship WHERE location = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM Addresses WHERE line_1 = \"1\" INTERSECT SELECT address_id FROM Addresses WHERE line_2 = \"2\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM DEGPROGRAMS", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM DEGETPROGRAMS", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT T2.department_description FROM DEPT_PROG_Prog_to_courses AS T1 JOIN DEPT_Prog_to_courses AS T2 ON T1.department_id = T2.department_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM DEGREATS AS T1 JOIN DEPTACURSE AS T2 ON T1.department_id = T2.department_id WHERE T1.degrees_program_id = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.degree_program_id FROM Department AS T1 JOIN Degree_Proprogram AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , COUNT(*) FROM DEGETYPES AS T1 JOIN DEGETYPES AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(*) FROM Department AS T1 JOIN Degree_Progrades AS T2 ON T1.department_id = T2.department_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM Department AS T1 JOIN Degree_Proprogram AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = \"Engineering\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM DEPARTMENT AS T1 JOIN DEG_PERG AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT T1.section_name , T1.section_description FROM Sections AS T1 JOIN Courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT t1.section_name , t1.section_description FROM sections AS t1 JOIN courses AS t2 ON t1.course_id = t2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM sections AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM sections AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T2.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.current_address_id = T2.current_address_id AND T1.degree_program_id = T2.degree_program_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT T1.department_description FROM departments AS T1 JOIN degree_programs AS T2 ON T1.department_id = T2.department_id WHERE T2.degree_summary_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT department_description FROM departments WHERE department_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name , T1.department_name , T1.department_id FROM student_enrolment AS T1 JOIN degree_programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.department_id HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name , T1.student_id , T1.date_left FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T1.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Undergraduates' AND T3.degree_program_id = 2 GROUP BY T1.student_id ORDER BY T1.date_left", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name FROM student_enrolment AS T1 JOIN student_enrolment_courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN degree_programs AS T3 ON T1.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor Degree'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T1.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelers'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_name FROM Degree_programs AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degrees_summary_name FROM degree_programs AS T1 JOIN student_enrolment_courses AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM degree_programs AS T1 JOIN student_enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T2.date_left FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name , T1.student_enrolment_count FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T1.degree_program_id = T3.degree_program_id GROUP BY T1.student_id ORDER BY T1.student_enrolment_count DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT name FROM sections WHERE course_id NOT IN (SELECT course_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT course_name FROM sections EXCEPT SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id JOIN Courses AS T3 ON T2.course_id = T3.course_id GROUP BY T1.course_name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM COURSE AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'North Carolina' EXCEPT SELECT T3.last_name FROM student_enrolment_courses AS T3 JOIN students AS T4 ON T3.student_id = T4.student_id JOIN degree_programs AS T5 ON T3.degree_program_id = T5.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'North Carolina' EXCEPT SELECT T3.last_name FROM students AS T3 JOIN student_enrolment AS T4 ON T3.student_id = T4.student_id JOIN degree_programs AS T5 ON T4.degree_program_id = T5.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id ORDER BY T2.semester_id DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Graduation' ORDER BY T1.date_left ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.middle_name , T2.last_name FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id ORDER BY T1.date_left ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.address_id != (SELECT address_id FROM Addresses WHERE address_id = (SELECT address_id FROM Addresses WHERE address_id != T1.current_address_id))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.perminent_address_id != T2.address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_left) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_left) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_left , date_first_registered FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , T1.transcript_details FROM transcripts AS T1 JOIN transcripts AS T2 ON T1.transcript_id = T2.transcript_id WHERE T1.transcript_date = (SELECT min(transcript_date) FROM transcripts)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students WHERE date_left = 'current'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT date_left FROM students ORDER BY date_first_registered DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT date_left FROM students ORDER BY date_left DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.department_id FROM student_enrolment AS T1 JOIN student_enrolment_courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN courses AS T3 ON T2.course_id = T3.course_id GROUP BY T1.department_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(count(*)) , curriculum_id FROM student_enrolment_courses GROUP BY curriculum_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT date_left FROM student_enrolment GROUP BY date_left ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT date_left , student_id FROM student_enrolment GROUP BY student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.ssn = 'Master' INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.ssn = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.student_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Degree_Proprogram AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_program_id = 'Master's' INTERSECT SELECT T1.student_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Degree_Proprogram AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_program_id = 'Bachelers'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.current_address_id) FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T1.address_id FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM students ORDER BY student_id DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_details FROM students ORDER BY student_id DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_name FROM sections WHERE section_name = 'section h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.perminent_address_id = T2.address_id WHERE T2.country = 'Haiti' OR T1.cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name FROM students AS T1 JOIN addresses AS T2 ON T1.perminent_address_id = T2.address_id WHERE T2.zip_postcode = 'Haitian 000-000' OR T1.cell_mobile_number = 09700166582", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM cartoon ORDER BY Title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT T1.Title FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.channel = T2.channel ORDER BY T1.title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT T1.title FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.id = T2.id WHERE T2.Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.id = T2.id WHERE T2.direction = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.id = T2.id WHERE T2.Directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT T2.TTitle , T1.Directed_by FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.id = T2.id ORDER BY T1.Air_Date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT T1.title , T2.directed_by FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.id = T2.id ORDER BY T1.original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT DISTINCT Directed_by FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by LIKE \"%Ben Jones%\" OR directed_by LIKE \"%Brandon Vietti%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Country , count(*) FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel GROUP BY T2.Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT content) , count(DISTINCT series_name) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT serial) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE Country = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT package_option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , count(*) FROM TV_channel GROUP BY Language ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , count(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , count(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT series_name FROM TV_series WHERE id = (SELECT id FROM cartoon WHERE title = \"The Rise of the Blue Beetle\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.name FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.title FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t2.title FROM TV_series AS t1 JOIN TV_channel AS t2 ON t1.channel = t2.id WHERE t1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T2.episode , T1.series_name , T1.rating FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id ORDER BY T1.rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.episode , T1.rating FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"The Top Entertainment Show\" GROUP BY T1.episode ORDER BY count(*) DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.air_date FROM TV_series AS T1 JOIN TV_series AS T2 ON T1.episode = T2.episode WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.air_date FROM TV_series AS T1 JOIN TV_series AS T2 ON T1.episode = T2.episode WHERE T1.title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT avg(TV_series.Wotalimitted) FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.episode = T2.id WHERE T2.series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Series_name , T1.Country FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Serial_name FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.episode = T2.id WHERE T2.series_name = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT count(*) , directed_by FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , T1.Series_name FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.Pixel_aspect_ratio_PAR = 100 AND T1.Hight_definition_TV = 100 AND T1.Content = \"HD TV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , t1.id FROM TV_channel AS t1 JOIN TV_series AS t2 ON t1.id = t2.channel WHERE t1.hight_definition_TV = \"HD\" AND t1.Country = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T2.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel JOIN TV_series AS T3 ON T1.channel = T3.id WHERE T3.Directed_by = \"Todd Casey\" AND T2.Written_by = \"Animation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2_written_by = \"Todd Casey\" AND T1.Series_name = \"Animation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_channel WHERE Country NOT IN (SELECT Country FROM TV_channel WHERE Content = \"Todd Casey\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Todd Casey\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.Serial_name , T2.Country FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.Channel = T2.id JOIN TV_series AS T3 ON T3.id = T2.id WHERE T3.Directed_by = \"Ben Jones\" INTERSECT SELECT T1.Serial_name , T2.Country FROM TV_series AS T1 JOIN TV_channel AS T2 ON T2.id = T1.id JOIN TV_series AS T3 ON T3.id = T2.id WHERE T3.Directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.Country , T1.Series_name FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Directed_by = \"Ben Jones\" INTERSECT SELECT T1.Country , T1.Series_name FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.CHANNEL WHERE T2.Directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel WHERE Country = \"United States\" GROUP BY Country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel WHERE country != \"Germany\" AND directed_by != \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people AS t1 JOIN poker_player AS t2 ON t1.people_id = t2.people_id WHERE t1.height = 2000000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people AS t1 JOIN poker_player AS t2 ON t1.people_id = t2.people_id WHERE t1.height = 2000000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT DISTINCT T1.Final_table_made , T1.Best_finish FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Best_finish DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT DISTINCT T1.Final_Table_Made , T1.Best_Finish FROM players AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE Earnings = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE Earnings = \"All\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT count(*) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(finish) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Best_Finish = \"Game_1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.birth_date FROM people AS T1 JOIN poker_player AS T2 ON T1.people_id = T2.people_id ORDER BY T1.earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player WHERE People_ID = (SELECT People_ID FROM people ORDER BY Height DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID = (SELECT People_ID FROM people WHERE Height > 200)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID = (SELECT People_ID FROM people WHERE Height > 200)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(*) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM votes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM votes WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name != 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT state , set_up_time FROM votes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T1.contestant_number , T1.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.contestant_number , T1.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T2.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT state FROM votes GROUP BY state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT state , phone_number , date FROM votes WHERE contestant_number = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.state FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 'Tabatha Gehling' INTERSECT SELECT T1.state FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE indeleous_year > 1950 GROUP BY countrycode ORDER BY indeleous_year DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE countrycode = 'USA' AND indepyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE government_form = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IndisessionForm = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.population) FROM country AS T1 JOIN city AS T2 ON T1.countrycode = T2.countrycode WHERE T2.district = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.TriageCount) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE countrycode = 'Anguila'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE countrycode = 'Anguilla'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT district FROM city WHERE name = 'Kabbe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT district FROM city WHERE name = 'Kabba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.CountryCode = 'Aruba' GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , min(lifeface) FROM city JOIN country AS T1 ON city.countrycode = T1.code WHERE countryname = 'Brazil' GROUP BY countryname", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lasesting FROM country WHERE countrycode = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT city.region , population FROM country AS T1 JOIN city AS T2 ON T1.id = T2.countrycode WHERE countrycode = \"Angentina\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT district , population FROM city WHERE name = 'Anguila'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lath) FROM country AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode WHERE T1.region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY alive LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY alive LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(population) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lath) FROM country WHERE countrycode = 'African' AND countrycode = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(livingyear) FROM country WHERE continent = 'Africa' AND countrycode = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(total_triage) FROM country AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(T1.Population) FROM country AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Continent = 'Asia' OR T1.Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT count(*) FROM city WHERE district = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(GNP) , count(*) FROM country WHERE countrycode = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(GNP) , count(*) FROM country WHERE countrycode = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode = \"America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT type) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT type) FROM countrylanguage WHERE countrycode = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(T2.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Language = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = 'Afghanistan'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = 'AF'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode GROUP BY T1.countrycode ORDER BY sum(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode JOIN city AS T3 ON T1.citycode = T3.id WHERE T1.language = \"De\" GROUP BY T2.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT continent FROM countrylanguage GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT continent FROM countryGROUP BY continent ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = 'English' INTERSECT SELECT count(*) FROM countrylanguage WHERE language = 'Dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"English\" AND T2.name = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT name FROM countrylanguage WHERE language = \"English\" INTERSECT SELECT name FROM countrylanguage WHERE language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode JOIN country AS T3 ON T2.language = T3.language WHERE T1.name = \"French\" INTERSECT SELECT name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode JOIN country AS T3 ON T2.language = T3.language WHERE T1.name = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM countrylanguage WHERE language = \"English\" INTERSECT SELECT name FROM countrylanguage WHERE language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Indisoficity = 'English' INTERSECT SELECT T2.Name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Indisoficity = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT continent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode WHERE T1.language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\" AND name = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT district FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.language = \"English\" OR T2.language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT district FROM city JOIN countrylanguage ON city.countrycode = countrycode AND language = 'Dutch' OR language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"English\" OR language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"English\" OR language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Cont Continent = 'Asia' GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Cont Continent = 'Asia' GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode JOIN city AS T3 ON T1.CountryCode = T3.CountryCode WHERE T3.District = 'Republic' GROUP BY T2.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T2.Language FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode JOIN country AS T3 ON T1.District = T3.District WHERE T3.Region = 'Republic' AND T3.CountryCode = 'US' GROUP BY T2.Language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT name FROM city WHERE population = (SELECT max(population) FROM city) AND language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT name FROM city WHERE countrycode = \"United States\" AND language = \"English\" ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , avg(lifeexpectancy) FROM country AS T1 JOIN country AS T2 ON T1.code = T2.code WHERE continent = 'Asia' GROUP BY T1.name ORDER BY area DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , max(lifeface) FROM country AS T1 JOIN city AS T2 ON T1.countrycode = T2.countrycode WHERE continent = 'Asia' GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(living_average) FROM countrylanguage WHERE language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lath) FROM countrylanguage WHERE language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = 'English')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM country WHERE head_of_state = \"Beatrix\" AND official_language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Name = 'Beatrix'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE percentage = 1 AND idemporal = 1 AND countrycode > 1930)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode = \"United States\" AND indepyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT countrycode FROM country WHERE continent = \"Europe\" AND surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = \"Europe\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT countrycode FROM country WHERE continent = 'Europe' AND surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'Africa' AND population < (SELECT min(population) FROM country WHERE region = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'Africa' AND population < (SELECT max(population) FROM country WHERE region = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE name NOT IN (SELECT countrycode FROM countrylanguage WHERE language = 'english')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT state_abbr FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = 'english')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT countrycode FROM countrylanguage EXCEPT SELECT countrycode FROM country WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE region != \"Republic\" AND countryname != \"United States\" AND countryname != \"United States of America\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode EXCEPT SELECT T3.name FROM city AS T3 JOIN countrylanguage AS T4 ON T3.countrycode = T4.countrycode WHERE T4.language = 'English' UNION SELECT T3.name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.code = T4.countrycode WHERE T4.language = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode = 'Europe' AND language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT name FROM city WHERE countrycode = \"Europe\" EXCEPT SELECT name FROM countrylanguage WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode JOIN city AS T3 ON T2.countrycode = T3.countrycode WHERE T2.region = 'Asia' AND T1.industry = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T2.region = \"Asia\" AND T3.indelfname = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , founded_year , countrycode FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , founded , countrycode FROM country ORDER BY population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.name , T1.leader FROM country AS T1 JOIN city AS T2 ON T1.countrycode = T2.countrycode ORDER BY T2.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T2.name FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode ORDER BY T2.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode GROUP BY T1.name HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode GROUP BY T2.countrycode HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city GROUP BY district HAVING max(population) - avg(population) > (SELECT avg(population) FROM city)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT T1.name , count(*) FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode GROUP BY T2.region HAVING avg(T2.Lifeexpectancy) > 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT count(*) , type FROM city WHERE average_lapse > 72 GROUP BY type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lisens) , count(*) FROM country WHERE continent = \"Europe\" AND avg(lisens) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT continent , sum(population) , avg(lifecycles) FROM country WHERE avg(lifecycles) < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , area FROM city WHERE district = \"top 5\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , countrycode FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = \"Europe\" AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(pollion) , avg(t1.tion) FROM country AS t1 JOIN city AS t2 ON t1.countrycode = t2.countrycode WHERE t1.cont Continent = 'North America' AND t1.surfacarearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(population) , avg(territory) FROM country WHERE continent = 'North America' AND countrycode = 'USA' AND surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage ORDER BY percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.name , T2.language FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT nationcode , count(*) FROM countrylanguage GROUP BY nationcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Population) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode JOIN countrylanguage AS T3 ON T2.Language = T3.Language WHERE T3.Language = 'Spanish' GROUP BY T1.CountryCode HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.code FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.countrycode JOIN city AS T3 ON T2.countrycode = T3.countrycode WHERE T2.name = 'Spanish' GROUP BY T1.code HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT T1.Enterprise FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID ORDER BY T2.Years_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT orchestra , YEAR_of_Founded FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE Type != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.name FROM orchestra AS T1 JOIN performance AS T2 ON T1.conductor_id = T2.orchina_id JOIN conductor AS T3 ON T1.conductor_id = T3.conductor_id GROUP BY T1.name HAVING T1.name != \"unknown\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN performance AS T2 ON T1.conductor_id = T2.orchina_id JOIN orchestic AS T3 ON T1.orchina_id = T3.orchina_id GROUP BY T3.orchina_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.Orchestra = \"Enforcement\" GROUP BY T2.Orchestra HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID JOIN conductor AS T3 ON T1.Conductor_ID = T3.Conductor_ID GROUP BY T2.Orchestra_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN performance AS T2 ON T1.conductor_id = T2.orchina_id JOIN orchestic AS T3 ON T1.orchina_id = T3.orchina_id WHERE T3.major_record_format = \"Enrollment\" GROUP BY T2.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT orchestra_id , COUNT(*) FROM performance GROUP BY orchestra_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.Enterprise_ID FROM orchestic AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T1.Enterprise_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT orchestra , COUNT(*) FROM orchestra GROUP BY orchestra ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT Major_record_format FROM orchestra GROUP BY Major_record_format ORDER BY frequency", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT orchestra , CONFANT_ID FROM orchestra GROUP BY orchestra HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT orchestra FROM orchestra GROUP BY orchestra ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra EXCEPT SELECT orchestra FROM performance", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra EXCEPT SELECT orchestra FROM performance", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT orchestra FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT orchestra FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT orchestra_id FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT orchestra_id FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra AS T1 JOIN orchestra AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.Major_Record_Format = \"CD\" OR T1.Major_Record_Format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra AS T1 JOIN orchestra AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.Record_Company = \"CD\" OR T1.Record_Company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_work FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID JOIN performance AS T3 ON T2.Orchestra_ID = T3.Orchestra_ID GROUP BY T1.year_of_work HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT * FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = \"Kyle\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "{\"sql\": \"SELECT student_id FROM friends WHERE friend_id = (SELECT student_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id = (SELECT liked_id FROM likes WHERE liked_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT student_id FROM friends WHERE student_id = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM Highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT grade , count(*) FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM friend GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM friend GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.ID = T2.student_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.name HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T1.student_id = 1 AND T1.friend_id = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM friend WHERE student_id = 20000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T1.student_id = 1 AND T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT student_id FROM friend EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT student_id FROM friend EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler EXCEPT SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friends)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT T1.student_id FROM friends AS T1 JOIN likes AS T2 ON T1.friend_id = T2.liked_id GROUP BY T1.student_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN highschooler AS T3 ON T2.friend_id = T3.id WHERE T3.id = (SELECT student_id FROM likes)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN highschooler AS T3 ON T2.friend_id = T3.id WHERE T2.friend_id = T3.friend_id AND T2.student_id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.liked_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id IN (SELECT friend_id FROM friend WHERE likes_id = 5) GROUP BY T1.name HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id IN (SELECT T1.id FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.friend_id WHERE T1.grade > 5 GROUP BY T2.friend_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friends AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T1.student_id = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = \"Kyle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T2.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.friend_id GROUP BY T2.grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id EXCEPT SELECT min(grade) FROM highschooler WHERE friend_id IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM Highschooler EXCEPT SELECT min(grade) FROM Highschooler WHERE friend_id IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT T1.state FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN breed_types AS T3 ON T2.breed_code = T3.breed_code JOIN treatment_types AS T4 ON T4.treatment_type_code = T4.treatment_type_code WHERE T3.breed_name = \"vitality\" INTERSECT SELECT T1.state FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN breed_types AS T3 ON T2.breed_code = T3.breed_code JOIN treatment_types AS T4 ON T4.treatment_type_code = T4.treatment_type_code WHERE T3.breed_name = \"vitality\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT DISTINCT T2.state FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T1.treatment_type_code = \"Veterinarian\" AND T3.state = \"State\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs WHERE date_departed = 'NULL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs WHERE date_departed = 'NULL' AND breed_code = \"healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T2.first_name , T2.last_name , T2.cell_phone FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" OR T2.date_of_treatment > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T2.last_name , T2.cell_phone FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" OR T2.role_code = \"health_caret\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'vet' OR role_code = 'guardian' EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'vet' OR role_code = 'guardian' EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.role_code , T1.email_address FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.role_code = T2.role_code JOIN dogs AS T3 ON T3.owner_id = T2.customer_id WHERE T2.treatment_type_code = \"medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT DISTINCT T1.role_code , T1.email_address FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.role_code = T2.role_code EXCEPT SELECT T3.role_code , T3.email_address FROM professionals AS T3 JOIN dogs AS T4 ON T3.profession_id = T4.owner_id JOIN treatment_types AS T2 ON T3.role_code = T2.role_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.breed_code = \"Labrador retrievable\" ORDER BY T2.age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.breed_code = \"golden retrievable\" GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id GROUP BY T1.role_code HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.role_code , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.profession_id = T2.profession_id GROUP BY T1.profession_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM Breeds WHERE breed_code = (SELECT breed_code FROM dogs GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM Breeds WHERE breed_code = (SELECT breed_code FROM dogs GROUP BY breed_code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE T2.cost_of_treatment = (SELECT cost_of_treatment FROM Treatments WHERE treatment_type_code = 'C')))))))))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.date_of_birth = (SELECT date_of_birth FROM Dogs WHERE weight = (SELECT max(weight) FROM Dogs))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description FROM treatments GROUP BY treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.treatment_type_description FROM treatments AS t1 JOIN treatment_types AS t2 ON t1.treatment_type_code = t2.treatment_type_code GROUP BY t1.treatment_type_code ORDER BY sum(t1.cost_of_treatment) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T2.guardian_id , T2.zip_code FROM Treatments AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.cost_of_treatment = (SELECT max(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.date_of_birth = (SELECT max(date_of_birth) FROM Dogs) GROUP BY T1.zip_code ORDER BY sum(treatment_type_code) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.profession_id , T2.cell_phone FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.profession_id = T2.profession_id GROUP BY T1.profession_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT DISTINCT T1.owner_id , T1.cell_phone FROM OWNERS AS T1 JOIN PROFESSIONS AS T2 ON T1.owner_id = T2.owner_id JOIN PPROFESSIONS AS T3 ON T2.profession_id = T3.profession_id WHERE T2.role_code = \"VENDER\" GROUP BY T1.cell_phone HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id WHERE T2.cost_of_treatment < (SELECT min(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.profession_id = T2.profession_id JOIN Treatments AS T3 ON T1.treatment_type_code = T3.treatment_type_code WHERE T1.treatment_type_code = \"Medicine\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.profession_id = T2.profession_id JOIN Dogs AS T3 ON T1.dog_id = T3.dog_id WHERE T3.date_of_birth = '12/12/2010'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM Treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM Treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.name = 'Labrador retrievable'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id JOIN Breeds AS T3 ON T1.breed_code = T3.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T2.breed_name , T3.date_of_treatment FROM treats AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id JOIN treatment_types AS T3 ON T3.treatment_type_code = T1.treatment_type_code WHERE T1.treatment_type_code = 'rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T1.breed_name = \"Rare_Runway\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T1.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.breed_code = \"Shattercore\" AND T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "{\"sql\": \"SELECT T2.name , T1.breed_name FROM Dogs AS T1 JOIN Breeds AS T2 ON T1.breed_code = T2.breed_code WHERE T1.date_of_birth = \\\"2011-11-12\\\" AND T1.date_of_birth = \\\"2012-11-12\\\" AND T1.date_of_birth = \\\"2013-11-12\\\" AND T1.date_of_birth = \\\"2014-11-12\\\" AND T1.date_of_birth = \\\"2015-11-12\\\" AND T1.date_of_birth = \\\"2016-11-12\\\" AND T1.date_of_birth = \\\"2017-11-12\\\" AND T1.date_of_birth = \\\"2018-11-12\\\" AND T1.date_of_birth = \\\"2019-11-12\\\" AND T1.date_of_birth = \\\"2020-11-12\\\" AND T1.date_of_birth = \\\"2021-11-12\\\" AND T1.date_of_birth = \\\"2022-11-12\\\" AND T1.date_of_birth = \\\"2023-11-12\\\" AND T1.date_of_birth = \\\"2024-11-12\\\" AND T1.date_of_birth = \\\"2025-11-12\\\" AND T1.date_of_birth = \\\"2026-11-12\\\" AND T1.date_of_birth = \\\"2027-11-12\\\" AND T1.date_of_birth = \\\"2028-11-12\\\" AND T1.date_of_birth = \\\"2029-11-12\\\" AND T1.date_of_birth = \\\"2030-11-12\\\" AND T1.date_of_birth = \\\"2031-11-12\\\" AND T1.date_of_birth = \\\"2032-11-12\\\" AND T1.date_of_birth = \\\"2033-11-12\\\" AND T1.date_of_birth = \\\"2034-11-12\\\" AND T1.date_of_birth = \\\"2035-11-12\\\" AND T1.date_of_birth = \\\"2036-11-12\\\" AND T1.date_of_birth = \\\"2037-11-12\\\" AND T1.date_of_birth = \\\"2038-11-12\\\" AND T1.date_of_birth = \\\"2039-11-12\\\" AND T1.date_of_birth = \\\"2040-11-12\\\" AND T1.date_of_birth = \\\"2041-11-12\\\" AND T1.date_of_birth = \\\"2042-11-12\\\" AND T1.date_of_birth = \\\"2043-11-12\\\" AND T1.date_of_birth = \\\"2044-11-12\\\" AND T", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_departed , date_arrived FROM dogs WHERE breed_code = \"Poodle 1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE breed_code = \"Poodle\" AND treatment_type_code = \"Healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.age = (SELECT min(age) FROM dogs) AND T1.breed_code = \"poodle_bearing\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM owners WHERE state = 'Hawaii' OR last_name = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Breeds AS T3 ON T2.breed_code = T3.breed_code WHERE T1.state = \"Hawaii\" OR T1.state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_departed , date_arrived FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_departed , date_arrived FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatment_types AS T1 JOIN dogs AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T1.treatment_type_code = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM dogs AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T1.gender = \"Pug\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM PROFESSIONS AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'P' AND T3.weight = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM Treatments AS T1 JOIN Dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.breed_code = \"Poodle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , T2.street , T2.city , T2.state FROM Professionals AS T1 JOIN Dogs AS T2 ON T1.profession_id = T2.profession_id JOIN Breeds AS T3 ON T2.breed_code = T3.breed_code WHERE T3.breed_name LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM PROFESSIONS WHERE last_name LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT T2.first_name , T2.last_name , T2.email_address FROM Owners AS T1 JOIN Doggus AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT T2.first_name , T2.last_name , T2.email_address FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT sum(cost_of_treatment) FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE breed_code NOT IN (SELECT breed_code FROM dogs WHERE date_of_birth = \"2010-12-20\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs AS t1 JOIN treatment_types AS t2 ON t1.treatment_type_code = t2.treatment_type_code WHERE t1.breed_code = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.abandoned_yn = 'no' AND T2.breed_code = 'pug'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE breed_code = \"poodle_buffie\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments WHERE dog_id = 1 AND treatment_type_code = 'Puggie' AND date_of_treatment = 'Puggie' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments WHERE dog_id = 'pug')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE breed_code = \"Pug\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE breed_code = \"Pug\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , cost_of_treatment FROM Treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charge_amount) FROM CHARGE_TYPE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM professionals WHERE role_code = 'VENDER'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_phone FROM professionals WHERE role_code = 'vet'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_type , size_type FROM Breeds AS T1 JOIN Sizes AS T2 ON T1.size_code = T2.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT breed_type , size_type FROM dogs WHERE gender = 'Pug'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.profession_id = T2.profession_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T2.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.profession_id = T2.profession_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer WHERE citizenship = 'Vocalist'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Country FROM singer WHERE Artist_Type = 'Vocalist'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Country FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID ORDER BY T2.Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , count(*) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , count(*) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Citzie FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Citzie ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT citizenship FROM singer GROUP BY citizenship ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_worth_millions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_worth_millions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Name , T1.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Title , T2.Singer_ID FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sale_1 > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sale_Millions > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , T1.Sales FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , T1.Sales FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT feature_type_name FROM ref_feature_types WHERE feature_type_code = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT property_type_description FROM Ref_Property_Types WHERE property_type_code = (SELECT property_type_code FROM Properties)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" OR property_type_code = \"Apartment\" AND room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..5225d9adba0cf4da0f5f850a81f4e3e03aa1a900 --- /dev/null +++ b/infer/qwen/spider_syn/fkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , state FROM musician GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.name , t2.capacity FROM concert AS t1 JOIN stadium AS t2 ON t1.stadium_id = t2.stadium_id WHERE t1.year >= 2014 GROUP BY t1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.time FROM time AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.time ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT name FROM singer WHERE age > 40 INTERSECT SELECT name FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T2.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id WHERE T3.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT max(weight) FROM Pets WHERE pettype = \"Puppy\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets WHERE pettype = 'Domestic' GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = \"F\" AND T1.Fname = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT name) FROM domestic_animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT name) FROM animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.pettype = \"Kitten\" OR T2.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid IN (SELECT petid FROM Pets WHERE PetType = \"Kitten\") INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid IN (SELECT petid FROM Pets WHERE PetType = \"Puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID WHERE T2.pettype = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.discipline , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.discipline , T1.age FROM Student AS T1 JOIN Pets AS T2 ON T1.StuID = T2.PetID WHERE T2.pettype = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Paw\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"dog\" EXCEPT SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(age) , max(age) , species FROM Animals GROUP BY species", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.PetID IN (SELECT PetID FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.petid FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Fname = \"Jack\" AND T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.StuID FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Lname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" AND T2.petage = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"kitten\" AND T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.Continent GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT t1.contid , t1 Continent , count(*) FROM continents AS t1 JOIN countries AS t2 ON t1.contid = t2.continent GROUP BY t1.contid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(DISTINCT continent) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , COUNT(*) , T2.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.makeid WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Make , T1.year FROM cars_data AS T1 JOIN car_names AS T2 ON T1.id = T2.model WHERE T1.year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t1.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.id ORDER BY t1.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.Mileage > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT t1.continent , count(*) FROM continents AS t1 JOIN car_makers AS t2 ON t1.continent = t2.country GROUP BY t1.continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.Id GROUP BY T2.Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.id GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT t2.Accelerate FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.model WHERE t1.FullName = 'Amec Hornet Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = 'Mazda' AND model = 'Monster Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullName = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.country = 'usa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN countries AS T3 ON T3.id = T1.countryid WHERE T3.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.Id WHERE T1.Country = \"United States\" GROUP BY T1.Country HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = 'Europe' GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T1.Horsepower) , T2.Maker FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.make GROUP BY T1.Maker HAVING T2.cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId ORDER BY T1.MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(cedispl) FROM cars_data WHERE model = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT accelerate , cylinders FROM cars_data GROUP BY cylinders ORDER BY max(accelerate) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.Model FROM car_names AS t1 JOIN model_list AS t2 ON t1.Model = t2.Model JOIN car_makers AS t3 ON t2.Maker = t3.Id GROUP BY t2.Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.model FROM model_list AS t1 JOIN car_names AS t2 ON t1.model = t2.model GROUP BY t2.model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'American Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.type FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.maker WHERE T1.fullName = 'General Motors' OR T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"Toyota\" AND T1.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(cylinders) FROM cars_data WHERE make = 'Volvo' ORDER BY accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(alculate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT T1.Maker) FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Maker GROUP BY T2.Maker HAVING count(DISTINCT T2.Maker) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model , T1.Horsepower FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Cylinders = 4 GROUP BY T1.Horsepower ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullName FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders != 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM cars_data WHERE horsepower NOT IN (SELECT min(horsepower) FROM cars_data) AND cylinders != 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) , min(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.fullName = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.Id WHERE T1.Maker != \"Toyota\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = 'fiat' GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Id HAVING count(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = \" Fiat : 185 \": 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM states AS T1 JOIN airlines AS T2 ON T1.airline = T2.abbr WHERE T2.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM states AS T1 JOIN airlines AS T2 ON T1.State Abbreviation = T2.Abbreviation WHERE T2.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , abbreviation FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T2.Airway , T1.Abbreviation FROM airlines AS T1 JOIN airports AS T2 ON T1.Abbreviation = T2.AirportCode WHERE T1.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(T1.AirwayCount) FROM (SELECT AirwayCount FROM flights GROUP BY AirwayCount) AS T1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.countryabbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airlines AS T3 ON T3.Uid = T2.airline WHERE T3.Abbreviation = \"UAL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM (SELECT airportcode FROM airports WHERE country = 'USA') AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT airportname , country FROM airports WHERE airportname = 'Alton'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , CountryAbbrev FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.CountryAbbrev = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.CountryAbbreviation = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T2.airportname = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Abbreviation = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.ABreviation = \"Jetblue\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.Airline = 'United Airlines' AND T2.AirportName = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'ASY' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T3.Uid = T1.airline WHERE T3.Abbreviation = \"United\" AND T2.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T3.airline = T1.airline WHERE T3.country = 'United' AND T2.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.country = 'Aberdeen' AND T1.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.country = \"Aberdeen\" AND T3.Abnvention = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.DestAirport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.DestAirport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Airway , T2.State FROM flights AS T1 JOIN (SELECT AirportCode , State FROM airports GROUP BY AirportCode ORDER BY count(*) LIMIT 1) AS T2 ON T1.DestAirport = T2.AirportCode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.countryabbreviation = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T2.airway FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T1.sourceairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.CountryAbbreviation = 'APG' INTERSECT SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.CountryAbbreviation = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.country = 'APG' INTERSECT SELECT T1.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.country = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DestAirport FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'CVO' EXCEPT SELECT DestAirport FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.country = 'CVO' EXCEPT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.country = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.Airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.Airway HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.Airway HAVING COUNT(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.Airline , T1.FLIGHTNO FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abbreviation = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.Airline WHERE T2.Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo , T1.SourceAirport , T1.DestAirport FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DestAirport , SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 INTERSECT SELECT T1.city FROM employee AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T2.age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.city HAVING avg(age) < 30 INTERSECT SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T1.Manager_name , T2.District FROM shop AS T1 JOIN evaluation AS T2 ON T1.Shop_ID = T2.Shop_ID GROUP BY T2.District ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM market GROUP BY name , district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , LOCATION FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T1.is_full_time = 'Yes' ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM employee AS T1 JOIN evaluation AS T2 ON T1.Employee_ID = T2.Employee_ID WHERE T2.Bonus = (SELECT max(Bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT Name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT manager_name FROM hiring WHERE is_full_time = 'Y')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T2.name , count(*) FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T2.manager_name , count(*) FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T1.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM hiring AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T1.is_full_time = 'N'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Papers", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Papers", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.paper_id , T1.paper_name , T1.paper_description FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text , T1.text FROM paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id WHERE T3.version_number = \"1.0\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_id , T1.layout_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t3.paragraph_id , t2.layout_id , t1.template_details FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id JOIN templates AS t3 ON t1.template_id = t3.template_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.paper_id , t1.layout_id , t1.template_details FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id JOIN Templates AS t3 ON t1.template_id = t3.template_id WHERE t3.template_type_code = \"Paper\" AND t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.Other_Details LIKE \"%text%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id WHERE T3.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Papers GROUP BY Template_ID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM layouts EXCEPT SELECT t1.template_id FROM documents AS t1 JOIN paragraphs AS t2 ON t1.paragraph_id = t2.paragraph_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM INFORMATION_SCHEMA.SCHEMATIC_LAYOUT", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.template_id , T2.version_number , T2.template_type_description FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code JOIN Paragraphs AS T3 ON T1.document_id = T3.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM Documents WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T1.edition_number , T2.layout_type_name FROM Templates AS T1 JOIN Layouts AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Template_Type_Description , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.Template_Type_Description", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN layout_types AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T2.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT template_type_code FROM templates GROUP BY template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code NOT IN (SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_details = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN Documents AS t3 ON t2.template_id = t3.template_id WHERE t3.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.template_type_description , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , layout_type FROM Papers GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.template_type_description FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t2.template_type_description ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM documents AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_code FROM Ref_Template_Types EXCEPT SELECT DISTINCT template_type_code FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_code FROM Ref_Template_Types EXCEPT SELECT DISTINCT template_type_code FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T2.template_type_name , T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Layouts AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T2.template_type_description , T1.template_type_name FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT T2.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT T1.layout_type_description FROM Ref_Template_Types AS T1 JOIN ref_layout_types AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT T1.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN Documents AS t3 ON t2.template_id = t3.document_id JOIN Paragraphs AS t4 ON t3.document_id = t4.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_details FROM Templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id JOIN Paragraphs AS t3 ON t2.document_id = t3.document_id WHERE t3.paragraph_text LIKE \"%text file%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM Ref_Template_Types WHERE template_type_description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM paragraphs AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE Paragraph_Text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text LIKE \"%Korea%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T2.paragraph_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text FROM paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T2.paragraph_text FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT T1.paper_id , count(*) FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paper_id ORDER BY T1.paper_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT T1.paper_id , count(*) FROM paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paper_id ORDER BY T1.paragraph_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.template_id , T2.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.paragraph_id , T1.text , count(*) FROM Paragraphs AS T1 GROUP BY T1.paragraph_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.paragraph_id FROM paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.paragraph_id , T2.document_name FROM paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T2.document_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT paragraph_id FROM paragraphs GROUP BY paragraph_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT paragraph_id FROM paragraphs GROUP BY paragraph_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T1.paragraph_text = 'Brazil' INTERSECT SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T1.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T1.paragraph_text = 'Brazil' INTERSECT SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T1.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT name FROM teacher EXCEPT SELECT name FROM teacher WHERE Hometown = \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T3.Course FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T3.Course FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID WHERE T1.Course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID WHERE T1.Course() = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.name , count(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T1.teacher_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T1.teacher_id HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_of_membership FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT T1.museum_id , T1.name FROM museum AS T1 JOIN visit AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id ORDER BY T1.total_spent DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Museum_ID , T1.Name FROM museum AS T1 JOIN visit AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T2.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT T2.total_spent FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN ( SELECT T2.visitor_id FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id WHERE T2.open_year > 2010 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_name = \"Tournament\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_name = \"Tournament\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches ORDER BY loser_rank ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.looser_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T2.minute ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'Yes' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.state_code FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.player_id ORDER BY tours DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.ranker_points = T3.ranking_points WHERE T2.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT loser_name , winner_name FROM matches ORDER BY minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches WHERE MATCH_NUM = (SELECT MATCH_NUM FROM matches GROUP BY MATCH_NUM ORDER BY minutes DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.abbr FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.abbr ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT year , count(*) FROM matches GROUP BY year", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.name , T2.ranking FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.year , T2.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T2.winner_hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand_type FROM players GROUP BY hand_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , loser_hand FROM matches WHERE round = \"best\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , RESULT FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(id) , min(id) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T1.id , T1.injured FROM death AS T1 JOIN ship AS T2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.lost_in_battle = T2.id WHERE T2.result = 'Completely destroyed' AND T1.ship_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T1.id) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.id , t1.name FROM ship AS t1 JOIN death AS t2 ON t1.id = t2.caused_by_ship_id GROUP BY t1.id ORDER BY sum(t2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander < 'Kaloyan' AND latin_commander > 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE result = 'loss' OR (SELECT count(*) FROM ship WHERE tonnage = 225)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.id WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses WHERE line_1 = 'include' UNION SELECT line_1 , line_2 FROM Addresses WHERE line_2 = 'include'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_type = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port\" AND department_name = \"Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.department_id FROM departments AS T1 JOIN degree_programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name FROM departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.degree_program_id GROUP BY T1.department_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_program_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id WHERE T2.department_name = \"Engineering\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT sum(T2.degree_summary_name) FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id WHERE T2.department_name = \"Engineering\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.section_name , T1.section_id FROM Sections AS T1 JOIN Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.section_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.semester_name , T1.student_id FROM transcripts AS T1 JOIN student_enrolment AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN student_enrolment_courses AS T3 ON T1.student_enrolment_id = T3.student_enrolment_id JOIN courses AS T4 ON T3.course_id = T4.course_id JOIN semester_courses AS T5 ON T3.semester_id = T5.semester_id JOIN courses AS T6 ON T5.course_id = T6.course_id JOIN semesters AS T7 ON T7.semester_name = T5.semester_name JOIN departments AS T8 ON T8.department_id = T5.degree_program_id JOIN degree_programs AS T9 ON T9.degree_program_id = T5.degree_program_id JOIN students AS T10 ON T10.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.semester_name , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Semesters AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT department_description FROM DEPARTMENTS WHERE department_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT DISTINCT T2.department_description FROM transcripts AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id WHERE T2.course_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"2nd Degree Program\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Undergrad Student\" INTERSECT SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Undergrad Student\" AND T2.semester_id = \"1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Bachelor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.department_name = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.degree_program_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T2.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T2.degree_program_id = T1.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_enrolment_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id , count(*) FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id EXCEPT SELECT T3.semester_name FROM semesters AS T3 JOIN student_enrolment_Courses AS T4 ON T3.semester_id = T4.semester_id JOIN courses AS T5 ON T4.course_id = T5.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id JOIN student_enrolment_courses AS T3 ON T2.section_id = T3.section_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_course_id JOIN Courses AS T3 ON T2.course_id = T3.course_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students WHERE date_first_registered = (SELECT min(date_first_registered) FROM Students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN transcript_contents AS T2 ON T1.student_course_id = T2.student_course_id JOIN transcripts AS T3 ON T2.transcript_id = T3.transcript_id JOIN degree_programs AS T4 ON T4.degree_program_id = T3.degree_program_id ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM Students WHERE permanent_address_id != current_address_id AND first_name != ''", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id EXCEPT SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_id , T1.line_1 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM Transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , first_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , \"transcript date\" FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT last_name , date_left FROM Students ORDER BY date_left DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_first_registered) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(count(*) , T1.student_enrolment_id) , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.course_id FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_course_id GROUP BY T1.student_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_id = T2.student_course_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.degree_program_id = 'Master' INTERSECT SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.degree_program_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id , T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = \"Masters\" INTERSECT SELECT T1.semester_id , T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.current_address_id) FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T2.department_name FROM students AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT first_name , last_name FROM students ORDER BY last_name , first_name REVERSE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_name FROM sections WHERE section_name = 'h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.country = \"Haiti\" UNION SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id AND T2.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id = (SELECT permanent_address_id FROM students WHERE cell_mobile_number = \"09700166582\") OR other_address_details = \"Haiti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM tv_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM tv_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(Language) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM tv_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM tv_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.Channel , T1.Series_name FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.Title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.id FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.Channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.episode , T1.rating FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.channel = T2.channel ORDER BY T1.rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Weekly_Rank , T2.Rating FROM TV_series AS T1 JOIN cartoon AS T2 ON T1.Channel = T2.Channel WHERE T2.Title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Series_name FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.Channel = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Series_name FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.Channel = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.Content = \"Animated\" AND T3.directed_by = \"Todd\" AND T3.write_by = \"Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT T1.State FROM state AS T1 JOIN cartoon AS T2 ON T1.id = T2.id EXCEPT SELECT T1.State FROM state AS T1 JOIN cartoon AS T2 ON T1.id = T2.id WHERE T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.id , t2.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = 'Ben Jones' INTERSECT SELECT t1.id , t2.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = 'Animation' INTERSECT SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = 'Ben Jones' INTERSECT SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = 'Michael Chang'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT channel FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.channel WHERE T1.directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_Channel EXCEPT SELECT T2.Package_Option FROM Cartoon AS T1 JOIN TV_Channel AS T2 ON T1.id = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_Channel EXCEPT SELECT T2.Package_Option FROM Cartoon AS T1 JOIN TV_Channel AS T2 ON T1.id = T2.id WHERE T1.directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM (SELECT T1.people_id FROM people AS T1 JOIN poker_player AS T2 ON T1.people_id = T2.people_id WHERE T2.Final_Table_Made = \"Game\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM (SELECT T1.People_ID FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Final_Table_Made = \"Game\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player ORDER BY Best_Finish DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE Nationality = \"Car_Gamers\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE Nationality = \"Car Gammer\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(T1.Final_Table_Made) FROM poker_player AS T1 WHERE T1.Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Nationality = \"Car\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Nationality = \"Car\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 3000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Cars\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Car Game\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS EXCEPT SELECT 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT state , created FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T1.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T2contestant_name , T1contestant_number FROM votes AS T1 JOIN CONTESTANTS AS T2 ON T1contestant_number = T2contestant_number GROUP BY T1contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM votes)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.area_code , T1.state FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state GROUP BY T1.state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.set_up_date , T1.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.state = 'GA' INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = \"Tabatha Gehling\" INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = \"Kelly Clauss\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independeyyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT Governmentform) FROM country WHERE Governmentform = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE governmentform = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t2.SurfaceArea) FROM country AS t1 JOIN country AS t2 ON t1.Code = t2.Code WHERE t1.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Antarctica'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE localname = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT name FROM country WHERE code = 'ANGUILLA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Capital WHERE T2.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage ORDER BY percentage DESC LIMIT 1 WHERE countrycode = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectability FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LIFEExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT region , population FROM country WHERE name = 'Angola'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , COUNT(*) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\" GROUP BY T1.Region", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(_life_expectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(tp.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T1.Continent = \"Africa\" AND T2.Region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Africa\" AND region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE name = 'Asia' OR name = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE GovernmentForm = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE Region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(t1.percentage) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE countrycode = (SELECT code FROM country WHERE name = 'Aruba' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = \"Yes\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.State FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.State ORDER BY AVG(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY SUM(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE language = \"English\" INTERSECT SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT continent) FROM countrylanguage WHERE language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Dutch\" OR T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = \"Republic\" GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = 'Republic' GROUP BY T1.Language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.countrycode = t2.countrycode WHERE t2.IsOfficial = 1 AND t2.Language = \"English\" GROUP BY t1.name ORDER BY sum(t2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.population , t1.lifeexpectancy FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code WHERE t1.Continent = \"Asia\" ORDER BY t1.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.isofficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.name != 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 1 AND language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.IsOfficial = 1 AND T2.Language = \"English\" AND T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.IsOfficial = 1 AND T2.Language = \"English\" AND T1.Capital = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE independyyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.State FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.nationabbrev FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.nation_abbr FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE governmentform != 'Republic' AND governmentform != 'State'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE governmentform != 'Republic' AND isofficial = 0 UNION SELECT code2 FROM countrylanguage WHERE isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 0 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 0 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Town FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Chinese\" AND T2.IsOfficial = 1 AND T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"Chinese\" AND T1.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independeyyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.Name , T1.Capital FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY T1.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.population , t1.capital FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code GROUP BY t1.code ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T2.name , count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code GROUP BY T1.countrycode HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT T1.GovernmentForm , COUNT(*) , T1.LifeExpectancy FROM country AS T1 JOIN country AS T2 ON T1.GovernmentForm = T2.GovernmentForm GROUP BY T1.GovernmentForm HAVING avg(T1.LifeExpectancy) > 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT GovernmentForm , COUNT(*) FROM country WHERE LifeExpectancy > 72 GROUP BY GovernmentForm", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) , continent FROM country WHERE lifeexpectancy < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT T1.Continent , sum(T2.Population) , avg(T2.lifeexpectancy) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code GROUP BY T1.Continent HAVING avg(T2.lifeexpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , region FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Europe\" AND T2.Population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t2.territory) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.territory > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.region > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population > 1600000 AND population < 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.Name FROM countrylanguage AS T1 JOIN state AS T2 ON T1.CountryCode = T2.Code GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(t1.percentage) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.CountryCode = t2.Code WHERE t1.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.Code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\" GROUP BY T1.Code ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.Code FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Spanish\" GROUP BY T1.Code HAVING COUNT(*) = SIZE(T1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor WHERE year_of_work = 'director' ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.major_record_format FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.major_record_format", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T1.Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT T1.Record_Company , COUNT(*) FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T1.Record_Company ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT Major_record_format FROM orchestra GROUP BY Major_record_format ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra != 'Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra != (SELECT T1.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT T1.record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id WHERE T1.year_of_founded < 2003 INTERSECT SELECT T1.record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id WHERE T1.year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE YEAR_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T2.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T2.orchestra_id HAVING T2.Type = \"Show\" AND T1.major_record_format = \"Million\" COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT T1.student_id , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.ID GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.id FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 55 AND T1.name = 'KYLE'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 4001", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend WHERE student_id = 1001", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = (SELECT T1.student_id FROM friend AS T1 JOIN highschooler AS T2 ON T1.friend_id = T2.id WHERE T2.name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM friends EXCEPT SELECT student_id FROM friends", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM friends EXCEPT SELECT student_id FROM friends", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM likes AS T1 JOIN friend AS T2 ON T1.student_id = T2.student_id GROUP BY student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM likes INTERSECT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) > 1 INTERSECT SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id WHERE T3.friend_id != T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2 AND T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes WHERE liked_id IN (SELECT id FROM friends WHERE student_id = \"Kyle\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T2.liked_id = T3.id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = 'guardian' INTERSECT SELECT state FROM Professionals WHERE role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = \"guardian\" INTERSECT SELECT state FROM owners AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = \"veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.charge_type = \"medical care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.cell_number , T1.first_name , T1.last_name FROM owners AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" OR T2.cell_number > 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM OWNERS AS T1 JOIN PROFESSIONALS AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T1.professional_id , T1.first_name , T1.last_name , T1.cell_number FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'veterinarian' EXCEPT SELECT first_name FROM professionals WHERE role_code = 'dog_name'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"Veterinarian\" EXCEPT SELECT first_name FROM Professionals WHERE role_code = \"Dog Name\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T3.dog_id = T2.dog_id WHERE T3.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT role_code , email_address FROM Professionals EXCEPT SELECT T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN owners AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.owner_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T2.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T2.cost_of_treatment = (SELECT sum(cost_of_treatment) FROM treatments) AND T1.treatment_type_code = \"Healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM dogs AS T1 JOIN treatment_types AS T2 ON T1.dog_id = T2.dog_id GROUP BY T1.breed_name ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_birth , T3.first_name FROM Dogs AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_Types AS T3 ON T2.role_code = 'Veterinary' WHERE T3.treatment_type_code = 'Medical Care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM charges AS T1 JOIN treatment_types AS T2 ON T1.charge_type = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.size FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.last_name = 'PUPPY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T4.date_of_treatment FROM Dogs AS T1 JOIN Breeds AS T2 ON T1.breed_code = T2.breed_code JOIN Treatment_Types AS T3 ON T3.treatment_type_code = \"Health\" JOIN T4 ON T4.dog_id = T1.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T4.date_of_treatment FROM dogs AS T1 JOIN treatment_ttypes AS T2 ON T1.dog_id = T2.dog_id JOIN treatments AS T3 ON T1.dog_id = T3.dog_id JOIN breeds AS T4 ON T1.breed_code = T4.breed_code WHERE T4.breed_name = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.name , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Medical Care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = \"P puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = \"health care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"Puppies\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"Puppies\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT T2.role_code , T2.street , T2.city , T2.state FROM owners AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE \"%West%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.email_address FROM owners AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.treatment_type_code = \"Health\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.gender = \"P\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE gender = \"Puppy\" );", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code != 'treatment'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code != 'dog_owner'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE gender = \"P puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE breed_code = \"Pug\" ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM Charges ORDER BY charge_type DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM PROFESSIONALS WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_name , size_description FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "{\"sql\": \"SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.age = 3\"]", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.role_code = 'Veterinary'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T2.treatment_type_description FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY net_workillions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT count(*) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Citizenship FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT country FROM singer GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Title , T1.Sales , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T1.Title , sum(T2.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT country FROM singer WHERE birth_year < 1945 INTERSECT SELECT country FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT feature_type_code FROM Other_Available_Features WHERE feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T2.property_type_description FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = \"house\" OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..e40d6a1b24fa25a93bdf566803594a393f929009 --- /dev/null +++ b/infer/qwen/spider_syn/rkl_train_0.6b_4b_kd0.6_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer WHERE is_male = 'female' ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , State FROM musician GROUP BY State", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.Stadium_ID FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID GROUP BY T1.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Name , T2.Capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.Stadium_ID = T2.Stadium_ID WHERE T1.Year >= 2014 GROUP BY T1.Stadium_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.year FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.Concert_Name , COUNT(*) , T1.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.Name , T3.Theme , COUNT(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID JOIN concert AS T3 ON T1.concert_ID = T3.concert_ID GROUP BY T3.Theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.Name FROM concert AS T1 JOIN singer AS T2 ON T1.concert_ID = T2.Singer_ID WHERE T1.Year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.Singer_ID = T3.Singer_ID WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Highest DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets) AND pet_type = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT min(weight) FROM Pets WHERE pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets WHERE pettype = 'domestic' GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T1.Fname = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.sex = 'F' AND T2.pettype = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT species) FROM animals WHERE pettype = \"domestic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT species) FROM animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname , T1.Lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid IN (SELECT T3.petid FROM Pets AS T3 JOIN Has_Pet AS T4 ON T3.petid = T4.petid WHERE T3.pettype = \"Kittens\" INTERSECT SELECT T5.petid FROM Pets AS T5 JOIN Has_Pet AS T6 ON T5.petid = T6.petid WHERE T5.pettype = \"Puppies\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pettype = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.petid IN (SELECT T2.petid FROM Pets AS T3 JOIN Has_Pet AS T2 ON T3.petid = T2.petid WHERE T3.pettype = \"Cat\") EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.petid IN (SELECT T2.petid FROM Pets AS T3 JOIN Has_Pet AS T2 ON T3.petid = T2.petid WHERE T3.pettype = \"Puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY petage ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(age) , max(age) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_age , pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T2.fname , T2.age FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T1.PetID = (SELECT PetID FROM Pets WHERE PetType = \"dog\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT T1.StuID , count(*) FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.PetID = T2.PetID GROUP BY T1.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Lname , T2.sex FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.Lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.Lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.Continent , T2.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.contid , T2.continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.contid = T2.continent GROUP BY T2.continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , count(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T2.Maker FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T1.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make , T2.Year FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Id WHERE T2.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id ORDER BY T2.year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.MakeId IN (SELECT Id FROM cars_data WHERE YEAR > 1980)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id = (SELECT id FROM car_makers GROUP BY id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN car_makers AS t2 ON t1.id = t2.id WHERE t1.make = \"Ford\" GROUP BY t1.make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT T2.Model , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE make = \"AMC Hornet Sportabout (SW)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE model = \"amc hornet sportabout\" AND make = \"hornet\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.continent = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.CountryId WHERE T2.Continent = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T2.Maker , T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.MakeId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T2.CountryName , T1.Id FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , avg(year) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Europe\" GROUP BY T1.Maker HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.continent = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T2.Maker FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T2.maker FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.makeid WHERE T1.cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Id IN (SELECT Make FROM car_names WHERE model = \"volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.MakeId GROUP BY T2.Model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.FullName , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T1.FullName = \"General Motors\" OR T2.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Id = T2.Id WHERE T1.Weight > 3500 OR T2.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(cylinders) FROM cars_data WHERE make = 'volvo' ORDER BY accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "{\"sql\": \"SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND Model = \"Volvo\"\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(alculate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Cylinders = 4 GROUP BY T2.Model ORDER BY MAX(T1.Horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , make FROM car_makers WHERE id IN (SELECT id FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders > 3))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT make , fullname FROM car_makers WHERE id NOT IN (SELECT make FROM cars_data WHERE horsepower >= 4 AND cylinders <= 4)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.Model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.id WHERE T2.Maker = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.id WHERE T2.maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId EXCEPT SELECT T2.CountryName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Auto\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE continent = 'North America' EXCEPT SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t2.id IN (SELECT id FROM car_makers WHERE maker = 'Ford')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.id , T2.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T2.id , T2.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T2.Model = \"fiat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Id HAVING count(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Mileage = 450", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.airline WHERE T1.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT country FROM airlines WHERE abbreviation = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT abbreviation FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , countryabbreviation FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirportName , T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(T2.airportname) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairportcode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , countryabbreviation FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT city , countryabbreviation FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.countryabbreviation = 'ATO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Aberdeen' AND T2.destairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ASY' INTERSECT SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ASY Airport\" AND T1.airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'AHD' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.Abbreviation = \"U.S.A.\", T2.AirportCode = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.uid WHERE T3.Above = 'Aberdeen' AND T3.Annoyance = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode JOIN airlines AS T3 ON T1.Airline = T3.UID WHERE T3.ABbr = \"United\" AND T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.airline = 'FL123' GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T2.sourceairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportname ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Airline , T1.AirportCode , T2.State FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode GROUP BY T1.Airline ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode , T1.Airline , T1.Airway FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.Airway ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airlines AS T1 JOIN airports AS T2 ON T1.airline = T2.countryabbreviation WHERE T2.airportname = 'AHD' INTERSECT SELECT T1.airway FROM airlines AS T1 JOIN airports AS T2 ON T1.airline = T2.countryabbreviation WHERE T2.airportname = 'Terminal'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.countryabbreviation = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.countryabbreviation = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'CVO' EXCEPT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airway FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airway = 'CVO' EXCEPT SELECT T1.airway FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airway = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airline FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid GROUP BY T1.airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.airline , T1.airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T2.FlightNo FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.CountryAbbrev = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T2.FlightNo FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.City = \"Aberdeen\" OR T1.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT DESTairport FROM flights UNION SELECT SOURCET airport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.district FROM shop AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id ORDER BY T1.number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM shop GROUP BY name ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , number_products FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM hiring GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE manager_name NOT IN (SELECT T1.manager_name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T2.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T1.year_awarded = 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents WHERE document_id IN (SELECT document_id FROM Documents GROUP BY document_id HAVING count(*) >= 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents WHERE document_name = \"Paper\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , document_id FROM Documents WHERE document_description LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.document_id , t1.layout_id , t2.document_description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.document_id , t1.paragraph_id , t2.template_details FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Text File\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id WHERE T3.template_type_code = 'PPT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id JOIN Paragraphs AS T3 ON T1.document_id = T3.document_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id JOIN Paragraphs AS t3 ON t2.document_id = t3.document_id GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT template_id FROM documents GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT document_id FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT template_id , version_number , template_type_description FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT layout_type FROM Layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM Ref_Template_Types JOIN Templates ON Templates.template_type_code = \"Layout\" WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type_name FROM Layouts WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT count(*) , layout FROM Paragraphs GROUP BY layout", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Layout_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types WHERE template_type_code NOT IN (SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) >= 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types EXCEPT SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Layouts AS t2 ON t1.template_type_code = t2.layout_type_code GROUP BY t2.layout_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Template_Type_Code) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , Template_Type_Code FROM Templates GROUP BY Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT layout_type_code FROM layouts WHERE name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM Documents WHERE document_type = \"Text\" AND template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.Document_Name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID JOIN Templates AS T3 ON T1.Template_ID = T3.Template_ID WHERE T3.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT t1.template_type_description , count(*) FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , layout_type FROM Documents GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT layout_type FROM Paragraphs GROUP BY layout_type ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM paragraphs AS T1 JOIN ref_template_types AS T2 ON T1.template_id = T2.template_id WHERE T1.paragraph_text LIKE \"%text%\" GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT template_type_code FROM Ref_Template_Types EXCEPT SELECT t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.document_id JOIN Documents AS t3 ON t2.document_id = t3.document_id WHERE t3.document_description = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types EXCEPT SELECT t2.template_type_description FROM Paragraphs AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.document_id = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT t1.template_type_description , t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT t1.template_type_description , t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.template_type_description , t2.template_type_code FROM Ref_Template_Types AS t1 JOIN Template_Types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT DISTINCT t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Paragraphs AS T2 ON T1.template_type_code = T2.document_id JOIN Documents AS T3 ON T2.document_id = T3.document_id WHERE T3.document_description = 'text file'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM Ref_Template_Types WHERE template_type_description = \"Presentation\" UNION SELECT layout_id FROM Templates WHERE template_type_code = \"Template\" AND date_effective_from > \"2020-01-01\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE Paragraph_Text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT paragraph_text FROM paragraphs WHERE document_id IN (SELECT document_id FROM documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Customer reviews'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.Document_id , T1.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.document_id , t1.document_name FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_details FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text LIKE '%Brazil%' AND paragraph_text LIKE '%Ireland%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID , T1.Course , T1.Curriculum FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T3.Name , T2.Course_ID FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID WHERE T1.Course_ID = (SELECT Course_ID FROM course WHERE Course.)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Name NOT IN (SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Name NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_of_membership FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT Museum_ID , Name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.ID , T2.Name , T2.Age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID JOIN museum AS T3 ON T1.Museum_ID = T3.Museum_ID GROUP BY T2.ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.ID , T2.name , T2.level_of_membership FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID ORDER BY T1.Total_spent DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit WHERE visitor_id IN (SELECT id FROM visitor WHERE level_of_membership = 'Guest')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN ( SELECT T2.id FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id WHERE T1.open_year > 2010 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_id = \"T1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_id = 'T1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches ORDER BY loser_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , MATCHES.Tourney_level FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.loser_age = (SELECT max(loser_age) FROM matches)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY tours DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.touryness FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY tours DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T2.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_name ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.ranking_points DESC LIMIT 1 JOIN matches AS T3 ON T3.winner_id = T1.winner_id WHERE T3.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id WHERE T2.country_code = \"AU\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.loser_id ORDER BY sum(T1.minutes) DESC LIMIT 1 UNION SELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY sum(T1.minutes) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , avg(T2.ranking) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM players GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.abbr FROM ranking AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.abbr ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.year , T2.match_num LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.winner_rank FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.match_num LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY sum(T2.winner_rank_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(killed) , min(killed) FROM death GROUP BY killed", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death GROUP BY injured", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T1.disposition_of_ship , T1.injured FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T1.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.id WHERE T1.ship_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE result = 'not lost' EXCEPT SELECT count(*) FROM ship WHERE Tonnage = 225", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM addresses WHERE line_1 = 'line 1' AND line_2 = 'line 2'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name = 'Math Curriculum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%math%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT T1.zip_postcode FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Port\" AND T1.department_name = \"Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.department_id FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.section_name , T1.section_id , count(*) FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.section_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments AS T1 JOIN degree_programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Undergraduate' GROUP BY T1.semester_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT T2.course_description FROM departments AS T1 JOIN courses AS T2 ON T1.department_id = T2.course_id WHERE T1.department_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T2.student_enrolment_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"2nd\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Bachelor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Bachelor’s\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , count(*) FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.degree_summary_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T2.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Student_Enrolment AS T1 JOIN Degree_Programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Degree_Programs AS T1 JOIN degree_programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T2.student_enrolment_id , count(*) FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T2.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT session_name FROM Semesters EXCEPT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_left = (SELECT min(date_left) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_enrolment_id JOIN student_enrolment_courses AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id JOIN courses AS T4 ON T3.course_id = T4.course_id WHERE T3.semester_id = 1 AND T4.semester_name = \"Fall\" ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.section_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.line_1 , T2.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM Transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , first_name , last_name FROM students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , other_details FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students WHERE date_left = '2023-04-28'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_left) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT date_left FROM students ORDER BY date_left DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(T2.student_enrolment_id) , T1.course_id FROM Student_Enrolment_Courses AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_enrolment_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Master' INTERSECT SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.last_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Student_Enrolment_Courses AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id JOIN Courses AS T4 ON T3.course_id = T4.course_id JOIN Degree_Programs AS T5 ON T4.course_id = T5.degree_program_id WHERE T5.degree_summary_name = 'Masters' INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Student_Enrolment_Courses AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id JOIN Courses AS T4 ON T3.course_id = T4.course_id JOIN Degree_Programs AS T5 ON T4.course_id = T5.degree_program_id JOIN Student_Enrolment_Courses AS T6 ON T3.student_enrolment_id = T6.student_enrolment_id JOIN Courses AS T7 ON T6.course_id = T7.course_id JOIN Degree_Programs AS T8 ON T7.degree_program_id = T8.degree_program_id WHERE T8.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.current_address_id) FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T1.line_1 , T1.city FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM students ORDER BY first_name , last_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_name FROM sections;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = 'h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" UNION SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" AND T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" UNION SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT language , count(*) FROM TV_channel GROUP BY language ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT language , count(*) FROM TV_channel GROUP BY language ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t2.series_name FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.channel FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.title FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t2.title FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.Episode , T1.Rating FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.id = T2.id ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT air_date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT air_date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Channel FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.id = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t2.series_name FROM tv_series AS t1 JOIN tv_channel AS t2 ON t1.id = t2.id WHERE t1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.id = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.id = T2.id WHERE T2.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , T1.Series_Name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.id WHERE T1.Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Todd Casey\" AND T2.written_by = \"Animation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Todd Casey\" AND T1.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel JOIN written_by AS t3 ON t2.id = t3.id WHERE t3.directed_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT title FROM cartoon WHERE written_by != 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.Series_name , T2.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.Series_name , T2.Country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT pixel_aspect_ratio_PAR , country FROM TV_channel WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT pixel_aspect_ratio_PAR , country FROM TV_channel WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T2.Package_Option FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_channel EXCEPT SELECT T2.Package_Option FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE height > 170;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE height > 170;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Name = \"Car gamer\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM people WHERE Nationality = \"American\") AND Final_Table_Made = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"Gamers\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 3000000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Trump\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"gamers\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS EXCEPT SELECT contestant_name FROM CONTESTANTS WHERE contestant_name = 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT T1.state , T2.created FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T2.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM votes AS T1 JOIN contestants AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.state , COUNT(*) FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state GROUP BY T1.state ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.state , T1.phone_number , T1.created FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state JOIN contestants AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state JOIN contestants AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independeyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE Governmentform = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T1.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(area) FROM country WHERE continent = 'Caribbean'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T2.Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT T2.Continent FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'ARUBA' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage WHERE CountryCode = \"ARU\" GROUP BY Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE name = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT region , population FROM country WHERE name = 'Angola'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , T1.Population FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT HeadOfState FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(population) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE governmentform = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE continent = 'North America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia' INTERSECT SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND code = 'AFR'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.State FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY SUM(Percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country WHERE language = \"English\" INTERSECT SELECT count(*) FROM country WHERE language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\" INTERSECT SELECT countrycode FROM countrylanguage WHERE language = \"Dutch\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name , T2.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = '1' AND T2.language = 'English' INTERSECT SELECT T1.name , T2.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = '1' AND T2.language = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(*) FROM country WHERE language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT region FROM countrylanguage WHERE language = \"English\" OR language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE isofficial = 1 GROUP BY language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE isofficial = 1 GROUP BY language HAVING count(*) = 1 INTERSECT SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" GROUP BY T1.name ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.language = \"English\" GROUP BY T1.name ORDER BY sum(T1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE continent = 'Asia' ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.Population , T1.LifeExpectancy FROM country AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Continent = \"Asia\" ORDER BY T1.Population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE IsOfficial = '1')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE IsOfficial = '1')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT isofficial) FROM countrylanguage WHERE isofficial = 'Official' AND code IN (SELECT DISTINCT country FROM country WHERE independyear < 1930)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(isofficial) FROM countrylanguage WHERE independyr = 1930 - 1 UNION SELECT sum(isofficial) FROM countrylanguage WHERE independyr < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country ORDER BY surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT max(population) FROM country WHERE continent = 'Asia') AND continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country WHERE country.code NOT IN (SELECT country.code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\") AND governmentform != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT headOfState FROM country WHERE governmentform != \"Republic\" AND language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode JOIN countrylanguage AS T3 ON T1.CountryCode = T3.CountryCode WHERE T3.IsOfficial = 0 AND T1.Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = \"No\" AND T1.CountryCode = \"EU\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Chinese\" AND T2.IsOfficial = 1 AND T1.CountryCode = \"AS-1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.id = T2.countrycode WHERE T2.Language = \"Chinese\" AND T2.IsOfficial = 1 AND T1.countrycode = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.name , T1.indepyear , T1.continent FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode ORDER BY T2.population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.name , T1.indepyear , T1.continent FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode ORDER BY T1.population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.name , T1.headofstate FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.population , t1.headofstate FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode ORDER BY t2.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.code HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city GROUP BY district HAVING avg(population) > population", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT T2.Name , COUNT(*) , avg(T1.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code GROUP BY T2.Name HAVING avg(T1.LifeExpectancy) > 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT GovernmentForm , sum(Population) FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) , continent FROM country WHERE avg(lifeexpectancy) < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT continent , sum(population) , avg(lifeexpectancy) FROM country WHERE lifeexpectancy < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , continent FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = \"Asia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = \"Europe\" AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Territory) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"North America\" AND T1.Territory > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.territory) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t1.territory > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage ORDER BY CountryCode ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.State FROM countrylanguage AS T1 JOIN state AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language , COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Percent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM country WHERE language = 'Spanish'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\" GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.Code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor WHERE type = 'director' ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE TYPE = \"Director\" GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T2.name , T1.orchestra FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT name FROM conductor WHERE conductor_id IN (SELECT conductor_id FROM orchestra GROUP BY conductor_id HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id JOIN CONDUCTOR AS T3 ON T3.conductor_id = T1.conductor_id GROUP BY T3.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE nationality = \"Italian\" GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id WHERE T1.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T2.name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.conductor_id = T2.conductor_id WHERE T1.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT TYPE FROM performance GROUP BY TYPE ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT major_record_format FROM orchestra GROUP BY major_record_format ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT T1.orchestra FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_ID NOT IN (SELECT orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.year_of_founded < 2003 INTERSECT SELECT T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.year_of_founded FROM performance AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T2.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT DISTINCT T2.grade FROM friend AS T1 JOIN highschooler AS T2 ON T1.ID = T2.friend_id WHERE T1.student_id = 123456789", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT name FROM highschooler WHERE student_id IN (SELECT student_id FROM friend GROUP BY student_id HAVING count(*) >= 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 525376", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 213456", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE student_id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friend INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T1.id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T1.id = T3.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN highschooler AS T3 ON T3.id = T2.friend_id WHERE T3.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T2.grade) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners WHERE role_code = 'guardian' INTERSECT SELECT state FROM owners WHERE role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM owners WHERE role_code = 'guardian' INTERSECT SELECT state FROM owners WHERE role_code = 'veterinary'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(t2.age) FROM treatments AS t1 JOIN dogs AS t2 ON t1.dog_id = t2.dog_id WHERE t1.charge_type = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.cell_number FROM Professionals AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"indiana\" UNION SELECT T1.owner_id , T1.first_name , T1.cell_number FROM Professionals AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"indiana\" OR T1.num_of_care_hours > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Indiana\" UNION SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Indiana\" OR T1.role_code = \"Veterinary\" GROUP BY T1.owner_id HAVING COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000 AND T2.treatment_type_code = 'health-care' AND T1.gender = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"Veterinarian\" OR role_code = \"Guardian\" EXCEPT SELECT first_name FROM Dogs WHERE role_code = \"Dog Name\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = 'Veterinarian' OR role_code = 'Guardian' EXCEPT SELECT first_name FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'Male' AND T3.weight > 10 AND T3.date_departed = '2023-11-01'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = 'health-care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM OWNERS AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN vets AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t2.breed_name FROM dogs AS t1 JOIN breeds AS t2 ON t1.breed_code = t2.breed_code GROUP BY t1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id JOIN dogs AS T3 ON T3.dog_id = T2.dog_id JOIN treatments AS T4 ON T3.dog_id = T4.dog_id ORDER BY T4.cost_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "{\"sql\": \"SELECT T1.owner_id , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM treatments WHERE dog_id IN (SELECT T2.dog_id FROM dogs AS T2 JOIN treatments AS T3 ON T3.dog_id = T2.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.treatment_type_description FROM treatments AS t1 JOIN treatment_types AS t2 ON t1.treatment_type_code = t2.treatment_type_code WHERE t1.charge_type = 'Health' AND t2.treatment_type_description != \"null\" ORDER BY sum(t1.charge_amount) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.size_description FROM treatments AS t1 JOIN sizes AS t2 ON t1.treatment_type_code = t2.size_code GROUP BY t1.treatment_type_code ORDER BY sum(t1.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , cell_number FROM Professionals GROUP BY professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , cell_number FROM Professionals WHERE role_code = 'Veterinarian' GROUP BY professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT date_of_treatment , first_name , last_name FROM treatments AS T JOIN professionals AS P ON T.professional_id = P.professional_id JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = 'M' AND D.age >= 2 AND D.age <= 5;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_birth , T2.first_name FROM Dogs AS T1 JOIN Professionals AS T2 ON T1.dog_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T3.first_name , T3.last_name , T2.size_description FROM Dogs AS T1 JOIN Sizes AS T2 ON T1.size_code = T2.size_code JOIN Professionals AS T3 ON T1.owner_id = T3.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.size_description FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.gender = \"M\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T5.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN breeds AS T3 ON T1.breed_code = T3.breed_code JOIN professionals AS T4 ON T3.treatment_type_code = T4.treatment_type_code JOIN treatment_types AS T5 ON T4.treatment_type_code = T5.treatment_type_code WHERE T3.breed_name = 'Pug' AND T5.date_of_treatment = (SELECT min(date_of_treatment) FROM treatments WHERE dog_id IN (SELECT dog_id FROM dogs WHERE breed_code = 'Pug' AND age > 2) )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T5.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN treatment_Types AS T3 ON T2.treatment_type_code = T3.treatment_type_code JOIN professionals AS T4 ON T3.professional_id = T4.professional_id JOIN breeds AS T5 ON T5.breed_code = T1.breed_code WHERE T5.breed_name = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.charge_type = 'Medical'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.charge_type = 'Health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "{\"sql\": \"SELECT T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog\\\" AND T2.weight = (SELECT min(weight) FROM dogs) AND T2.name = \\\"Puppy\\\" AND T2.age = (SELECT min(age) FROM dogs) AND T2.gender = \\\"Dog", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Owners WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" UNION SELECT email_address FROM Professionals WHERE state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.treatment_type_code = \"Healthcare\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.treatment_type_code = 'Health Care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"P\" AND T3.age >= 3 AND T3.name = \"puppies\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"male\" AND D.age < 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals AS T1 JOIN Owners AS T2 ON T1.street = T2.street WHERE T2.city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.treatment_type_code = \"Health\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.first_name = \"guardian\" AND T2.gender = \"male\" AND T2.age >= 1 AND T2.date_departed = \"null\" AND T2.date_arrived = \"null\" AND T2.date_departed != \"null\" AND T2.date_arrived != \"null\" AND T2.date_departed != \"null\" AND T2.date_arrived != \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE gender = 'dog' AND age > 3);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Professionals WHERE role_code = 'Veterinarian' EXCEPT SELECT T1.role_code FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = 'Veterinary' EXCEPT SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = 'Male' AND D.age < 14", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'dog' AND breed_code = 'Pug'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE gender = 'dog' AND breed_code = 'Pup';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE gender = 'dog' AND breed_code = 'puppy' ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE gender = 'P' AND breed_code = 'pug' ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM CHARGES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals WHERE role_code = 'Veterinary'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_name , size_description FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T1.role_code = \"Veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer WHERE Highest_Position = \"Vocalist\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Country FROM singer WHERE Position = \"Vocal\" GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Country FROM singer GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(networth Millions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(networth millions) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T1.Name , SUM(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Country FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Country FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT t2.feature_type_name FROM Other_Available_Features AS t1 JOIN Ref_Feature_Types AS t2 ON t1.feature_type_code = t2.feature_type_code WHERE t1.feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT property_type_description FROM Ref_Property_Types WHERE property_type_code = (SELECT property_type_code FROM Other_Property_Features WHERE feature_id = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..e426773077aaec0e30b042be15979811d429ae56 --- /dev/null +++ b/infer/qwen/spider_syn/rkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer WHERE is_male = 'Y' ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , COUNT(*) FROM singer WHERE is_male = 'Y' GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , State FROM singer GROUP BY State", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , T1.Stadium_ID FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(T1.time) FROM time AS T1 JOIN concert AS T2 ON T1.time = T2.start_time GROUP BY T2.start_time ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium EXCEPT SELECT T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.concert_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.name , T2.theme , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id WHERE T3.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.highest = (SELECT highest FROM stadium ORDER BY capacity DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_age FROM Pets WHERE pet_type = \"youngest\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets WHERE pettype = 'domestic' GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Sex = \"F\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM Pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT name) FROM Animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kittens\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppies\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.pet_type = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'Puppy' EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = 'Cat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_age , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(age) , max(age) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_age , pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid WHERE T2.petid IN (SELECT petid FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE pet_age > 100)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.StuID FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.Lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.StuID FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.Lname = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.fname , T2.sex FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.petage = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" AND T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student EXCEPT SELECT T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T2.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Maker , T2.Year FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Model WHERE T2.Year = (SELECT min(YEAR) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Continent = T2.Continent GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.StateName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Maker ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Maker ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT T2.Maker , T2.FullName , COUNT(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id GROUP BY T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE makeid IN (SELECT make FROM car_makers WHERE fullname = \"Amc hornet sportabout (sw)\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT accelerate FROM cars_data WHERE model = \"AMC Hornet Sportabout\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullName = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.Countryid WHERE T2.CountryName = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE year = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT maker , model FROM model_list", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT DISTINCT T2.FullName , T1.Id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Vehicle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.Continent FROM car_makers AS T1 JOIN continents AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Vehicle\" AND T2.Continent = \"Europe\" GROUP BY T2.Continent HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT t1.countryname FROM countries AS t1 JOIN car_makers AS t2 ON t1.countryid = t2.country WHERE t1.countryname = \"Europe\" GROUP BY t1.countryname HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , T2.Maker FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T1.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.maker FROM car_names AS T1 JOIN cars_data AS T2 ON T1.model = T2.model WHERE T2.cylinders = 3 GROUP BY T1.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model ORDER BY T1.MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE model = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Model = \"VOLVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Acceleration) , Cylinders FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Acceleration) FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.MakeId = T2.Model AND T1.MakeId IN (SELECT T3.Model FROM car_names AS T3 JOIN car_makers AS T4 ON T3.MakeId = T4.Id GROUP BY T3.Model ORDER BY COUNT(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM model_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE FullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T2.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T2.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.Id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.MakeId WHERE T2.Weight > 3500 OR T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"General Motors\" INTERSECT SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Id = (SELECT Model FROM cars_data WHERE Weight > 3500)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND Model = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY Maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names WHERE make = \"Toyota\" AND cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.Model WHERE T1.Cylinders = 4 GROUP BY T2.Model ORDER BY MAX(T1.Horsepower) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullName FROM car_makers WHERE id IN (SELECT makeid FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data)) EXCEPT SELECT T1.makeid , T1.fullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.makeid WHERE T2.cylinders > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE id IN (SELECT makeid FROM cars_data WHERE horsepower < 4 GROUP BY makeid HAVING count(*) < 4)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.id WHERE T1.maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.make WHERE T1.maker = \"Ford\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Automobile\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries EXCEPT SELECT t1.countryname FROM countries AS t1 JOIN continents AS t2 ON t1.continent = t2.ContId JOIN car_makers AS t3 ON t3.country = t1.countryid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Maker HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T2.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T2.Maker HAVING COUNT(*) >= 2 INTERSECT SELECT T1.Id , T2.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T2.Maker HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker WHERE T2.Model = 'FIAT' UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Id HAVING COUNT(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T1.FullName = \"Fiata\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.Airline JOIN airports AS T3 ON T2.DestAirport = T3.AirportCode WHERE T1.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.country FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport JOIN airlines AS T3 ON T2.airline = T3.uid WHERE T3.airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT abbreviation FROM airlines WHERE airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT abbreviation FROM airlines WHERE airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT airportname , airportcode FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.airportname , T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(airports.airportcode) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportcode LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairportcode WHERE T1.airportname = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT T1.AirportName , T1.Country FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T2.DestAirport = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT airportname , country FROM airports WHERE airportname = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Terminal ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = 'ATL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"City Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = 'Aberdeen' AND T1.city = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" AND T1.DestAirport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid WHERE T2.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ASY' AND T1.Airline = 1234", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"ASY Airport\" AND T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = 'AHD' AND T1.Airline = 101", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD Airport\" AND T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'Aberdeen' AND T1.Airline = 101", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" AND T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport JOIN airports AS T3 ON T2.DestAirport = T3.AirportCode GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT destairport FROM flights GROUP BY destairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT destairport FROM flights GROUP BY destairport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportName , T2.State FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T2.SourceAirport ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode , T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airways AS T1 JOIN flights AS T2 ON T1.airway = T2.airway WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.airline = 112 AND T2.airline = 114", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airway FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'CVO' EXCEPT SELECT T1.airway FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airway FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.sourceairport = 'CVO' EXCEPT SELECT T1.airway FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportname HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.airline , T1.FlightNo FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop GROUP BY manager_name ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM shop GROUP BY name , district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , LOCATION FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T2.bonus = (SELECT max(bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T2.bonus = (SELECT max(bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM hiring GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T2.name , count(*) FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T1.Premium) FROM assessment AS T1 JOIN evaluation AS T2 ON T1.year_awarded = T2.year_awarded", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id , document_name , document_description FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_name , T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.document_id , t1.layout_id , t2.document_description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.document_id , t1.layout_id , t2.document_description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM Document_layout WHERE document_type = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id WHERE T3.template_type_code = 'PPT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id JOIN Paragraphs AS T3 ON T1.document_id = T3.document_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Paragraphs GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT document_id , template_type_code FROM layouts GROUP BY document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT layout_id , layout_type FROM Layouts GROUP BY layout_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT template_id FROM documents GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM layouts EXCEPT SELECT t1.template_id FROM layouts AS t1 JOIN documents AS t2 ON t1.template_id = t2.template_id JOIN paragraphs AS t3 ON t2.document_id = t3.document_id WHERE t3.paragraph_text = \"paper\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT t1.template_type_code , t2.version_number , t2.template_type_description FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT layout_type FROM layout", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_template_types", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Layouts WHERE type = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM layouts WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type_name FROM layouts WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT layout_type , count(*) FROM Layout GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN layouts AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT layout_type FROM Layouts GROUP BY layout_type HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT template_type_description FROM ref_template_types EXCEPT SELECT t1.template_type_description FROM ref_template_types AS t1 JOIN layouts AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Template_Type_Code) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT layout_type_code FROM layouts WHERE name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.layout_type_code FROM Layouts AS t1 JOIN Documents AS t2 ON t1.document_id = t2.document_id WHERE t2.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT DISTINCT t1.document_name FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t2.paragraph_text LIKE \"%text%\" AND t1.document_description = \"text file\" AND t1.document_description LIKE \"%layout type code BK%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT t1.document_name FROM documents AS t1 JOIN templates AS t2 ON t1.template_id = t2.template_id JOIN ref_template_types AS t3 ON t2.template_type_code = t3.template_type_code WHERE t3.template_type_description = \"Layout\" AND t2.version_number = 20230501 AND t1.document_id = 1010101", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT t1.template_type_description , count(*) FROM Ref_template_types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_description", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , layout_type FROM documents GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT layout_type FROM Paragraphs GROUP BY layout_type ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types EXCEPT SELECT T2.template_type_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id EXCEPT SELECT T3.template_type_description FROM Paragraphs AS T3 JOIN Documents AS T4 ON T3.document_id = T4.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT template_type_description FROM Ref_Template_Types EXCEPT SELECT t2.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN Paragraphs AS t3 ON t2.document_id = t3.document_id WHERE t3.paragraph_text LIKE \"%text%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T2.layout_type_name , T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT t1.template_type_description , t2.template_type_code FROM Ref_template_types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT template_type_description FROM ref_template_types WHERE template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.layout_type_description , t1.layout_type_name FROM Ref_Template_Types AS t1 JOIN Layout_Type_Name AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN Paragraphs AS t3 ON t2.document_id = t3.document_id WHERE t3.paragraph_text LIKE \"%text%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.document_id JOIN Documents AS t3 ON t2.document_id = t3.document_id WHERE t3.document_description = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM layouts WHERE template_type_description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM templates AS T1 JOIN documents AS T2 ON T1.template_id = T2.template_id JOIN paragraphs AS T3 ON T2.document_id = T3.document_id WHERE T3.paragraph_text = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM PARAGRAPHS WHERE paragraph_text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM paragraphs AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT paragraph_text FROM paragraphs WHERE document_id IN (SELECT document_id FROM documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T1.paragraph_text FROM paragraphs AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Customer reviews'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT T1.paper_id , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paper_id ORDER BY T1.paper_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.template_id , T1.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.document_id , t1.document_name FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id GROUP BY t1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_details FROM Templates AS T1 JOIN Paragraphs AS T2 ON T1.template_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.Template_ID FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T2.paragraph_text = 'Brazil' INTERSECT SELECT T1.Template_ID FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T2.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher WHERE Teacher_ID IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT DISTINCT T1.Hometown FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.grade FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Grade FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Course_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course_Name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T1.Course_ID = T3.Course_ID WHERE T3.Course_Name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_of_membership FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.ID , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID WHERE T1.Total_spent = (SELECT max(T1.Total_spent) FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.ID)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id GROUP BY T1.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT visitor_id FROM visit WHERE museum_id > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches WHERE tourney_id = 'L'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches ORDER BY loser_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.round = 10 AND T2.year = 2023 ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id WHERE T2.minutes = (SELECT max(minutes) FROM matches)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_name ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank + T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN players AS T3 ON T2.winner_id = T3.player_id WHERE T3.country_code = \"Australia\" ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.loser_name , T2.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.loser_id ORDER BY sum(T1.minutes) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT state FROM matches GROUP BY state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" AND T1.winner_hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = 'left' AND T1.tourney_name = 'WTA Championships'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(killed) , min(killed) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T1.note , T1.injured FROM death AS T1 JOIN ship AS T2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.id WHERE T1.ship_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' INTERSECT SELECT DISTINCT name FROM battle WHERE latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE result = 'not lost' EXCEPT SELECT count(*) FROM ship WHERE Tonnage = 225", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT * FROM Addresses WHERE line_1 = 'Line 1' AND line_2 = 'Line 2'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%math%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT T2.zip_postcode FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.department_id FROM departments AS T1 JOIN degree_programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T2.department_id FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T2.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments WHERE department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments WHERE department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T2.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T2.course_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.semester_name , T1.student_enrolment_id FROM student_enrolment AS T1 JOIN Semesters AS T2 ON T1.semester_id = T2.semester_id JOIN students AS T3 ON T1.student_id = T3.student_id GROUP BY T1.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT course_description FROM courses WHERE course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T2.student_enrolment_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"2nd\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.department_name = 'Bachelor\\'s Degree Program'\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , count(*) FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Degree_Programs AS T1 JOIN Degree_Programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_enrolment_id , count(*) FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT section_name FROM sections WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT section_name FROM sections WHERE section_name NOT IN (SELECT T1.section_name FROM sections AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_name HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id JOIN student_enrolment_courses AS T3 ON T2.section_id = T3.section_id GROUP BY T1.course_name HAVING count(*) > 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM students WHERE permanent_address_id IN (SELECT T1.line_1 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.state_province_county = \"North Carolina\") EXCEPT SELECT T2.last_name FROM students AS T2 JOIN student_enrolment AS T3 ON T2.student_id = T3.student_id JOIN degree_programs AS T4 ON T3.degree_program_id = T4.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.student_id , T1.date_first_registered FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN transcript_contents AS T2 ON T1.student_course_id = T2.student_course_id JOIN student_enrolment AS T3 ON T3.student_enrolment_id = T2.student_enrolment_id JOIN degree_programs AS T4 ON T3.degree_program_id = T4.degree_program_id JOIN departments AS T5 ON T4.department_id = T5.department_id ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Transcripts AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id ORDER BY T2.transcript_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM Students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name , last_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T2.section_name FROM Addresses AS T1 JOIN Sections AS T2 ON T1.address_id = T2.course_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.perminent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM Transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , other_details FROM Transcripts GROUP BY other_details ORDER BY transcript_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_left) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT date_left FROM students ORDER BY date_left DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_enrolment_id , T2.course_id , count(*) FROM Student_Enrolment_Courses AS T1 JOIN Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = 'Master' INTERSECT SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Masters' INTERSECT SELECT T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id JOIN Students AS T3 ON T2.student_id = T3.student_id WHERE T3.first_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T1.department_name FROM Departments AS T1 JOIN Student_Enrolment AS T2 ON T1.department_id = T2.department_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM Students ORDER BY first_name , last_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM STUDENTS ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_name FROM sections WHERE section_name = 'h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" UNION SELECT T1.first_name , T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.country = \"Haiti\" AND T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT DISTINCT directed_by FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE Written_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , count(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.series_name FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T2.channel FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t1.title FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT t2.title FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT * FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.episode , T2.rating FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.channel ORDER BY T2.rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT original_air_date FROM cartoon WHERE title = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Weekly_Rank FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.id WHERE T1.Content = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.series_name FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t1.series_name FROM TV_channel AS t1 JOIN tv_series AS t2 ON t1.id = t2.channel WHERE t2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Todd Casey\" AND T2.written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM TV_channel EXCEPT SELECT t1.country FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT state FROM cartoon EXCEPT SELECT T1.state FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.content = 'Animation' AND T1.written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM TV_channel WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T2.package_option FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T1.package_option FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM car_gameer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE height > 180", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Name = \"Car gamer\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM people WHERE Nationality = \"Chinese\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT T1.Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM people AS T2 JOIN poker_player AS T1 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T1.Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T1.Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Best\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Car Game\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_number FROM CONTESTANTS WHERE contestant_name != 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT T2.state , T1.created FROM VOTES AS T1 JOIN AREA_CODE_STATE AS T2 ON T1.state = T2.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT state FROM votes GROUP BY state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.state , T1.phone_number , T1.contestant_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state JOIN CONTESTANTS AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state JOIN CONTESTANTS AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T2.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Antarctic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE code = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.region FROM country AS T1 JOIN city AS T2 ON T1.capital = T2.name WHERE T2.name = 'Kabul'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.region FROM country AS T1 JOIN city AS T2 ON T1.capital = T2.population WHERE T2.name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = \"ARAB (Aruba)\" GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'ARU' GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT region , population FROM country WHERE name = 'Angola'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.region , count(*) FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.name = \"Angola\" GROUP BY T1.region", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE REGION = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(gnp) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(gnp) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND countrycode = 'AFR' AND governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND region = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT population FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE governmentform = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE continent = 'North America' OR continent = 'South America' OR continent = 'Central America' OR continent = 'West America' OR continent = 'East America'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = \"ARBA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = 'Aruban'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND code = \"AF\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "{\"sql\": \"SELECT count(*) FROM countrylanguage WHERE isofficial = 1 AND countrycode = 'AF'}\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode GROUP BY t1.continent ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"english\" INTERSECT SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name , T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"english\" INTERSECT SELECT T1.name , T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE t1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.language = \"english\" OR T1.language = \"dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.language = \"Dutch\" OR T1.language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"english\" UNION SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.language = \"dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = 'Asia' GROUP BY T2.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = \"Republic\" GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE isofficial = 1 GROUP BY language HAVING count(*) = 1 INTERSECT SELECT language FROM countrylanguage WHERE governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"english\" GROUP BY T1.name ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.countrycode = t2.countrycode WHERE t2.Language = \"English\" ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN T2 AS T2 ON T1.code = T2.code WHERE T1.continent = 'Asia' ORDER BY T1.surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN country AS T2 ON T1.code = T2.code WHERE T1.continent = 'Asia' ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE code NOT IN ( SELECT countrycode FROM countrylanguage WHERE isofficial = 0 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 0)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT T1.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.IndepYear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage WHERE independyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent != 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent != ‘Europe’)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'African' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'African' AND population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT state_code FROM state WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode EXCEPT SELECT T1.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE governmentform != 'Republic' AND isofficial = 0 UNION SELECT code2 FROM countrylanguage WHERE language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code2 FROM country WHERE governmentform != 'Republic' AND isofficial = 0 AND language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 0 AND T1.countrycode = (SELECT code FROM country WHERE continent = \"Europe\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 0 AND T1.countrycode = 'EU'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.language = \"Chinese\" AND T2.isofficial = 1 AND T1.countrycode = \"ASIA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"Chinese\" AND T1.continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , indepyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT capital , head_of_state , name FROM country ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.population , t1.capital FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t2.district = 1 GROUP BY t1.capital ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.code HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.name HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT governmentform , count(*) FROM country WHERE lifeexpectancy > 72 GROUP BY governmentform", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT governmentform , count(*) FROM country WHERE lifeexpectancy > 72 GROUP BY governmentform", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , count(*) , continent FROM country WHERE lifeexpectancy != \"null\" GROUP BY continent HAVING avg(lifeexpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT continent , sum(population) , avg(lifeexpectancy) FROM country WHERE lifeexpectancy < 72 GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , continent FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , continent FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN continent AS T2 ON T1.continent = T2.number WHERE T2.name = \"Europe\" AND T1.population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(population) , avg(territory) FROM country WHERE continent = \"North America\" AND territory > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.surfacearea) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t1.surfacearea > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage GROUP BY language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.State FROM countrylanguage AS T1 JOIN city AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T2.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode , T2.Language , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T2.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE language = \"Spanish\" GROUP BY countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.CountryCode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T1.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY year_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor WHERE year_of_work = 1990 ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE year_of_work = (SELECT max(year_of_work) FROM conductor)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra_id FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.orchestra_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id JOIN performance AS T3 ON T2.orchestra_id = T3.performance_id JOIN show AS T4 ON T3.performance_id = T4.performance_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.conductor_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id JOIN performance AS T3 ON T2.orchestra_id = T3.performance_id JOIN show AS T4 ON T3.performance_id = T4.performance_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id JOIN performance AS T3 ON T2.orchestra_id = T3.orchestra_id JOIN show AS T4 ON T3.performance_id = T4.performance_id WHERE T3.type = \"Serie\" GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT record_type FROM orchestra GROUP BY record_type ORDER BY count(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT major_record_format FROM orchestra GROUP BY major_record_format ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT T1.Record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.year_of_founded < 2003 INTERSECT SELECT T1.Record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID WHERE T1.year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT DISTINCT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM FREQ GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 1001", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 59368", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler EXCEPT SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friend INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T1.id = T3.student_id WHERE T2.friend_id = T3.friend_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id JOIN likes AS T3 ON T1.id = T3.student_id WHERE T2.friend_id = T3.friend_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM professionals WHERE role_code = 'Guardian' INTERSECT SELECT state FROM professionals WHERE role_code = 'Veterinary'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM professionals WHERE role_code = \"guardian\" INTERSECT SELECT state FROM professionals WHERE role_code = \"veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'medical'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.treatment_type_description = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.cell_number FROM professionals AS T1 JOIN owners AS T2 ON T1.professional_id = T2.professional_id WHERE T2.state = \"Indiana\" OR T1.num_of_medical_care = 2 + 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT professional_id , first_name , last_name , cell_number FROM professionals WHERE state = \"Indiana\" UNION SELECT professional_id , first_name , last_name , cell_number FROM professionals WHERE count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"Veterinarian\" OR role_code = \"Guardian\" EXCEPT SELECT T1.first_name FROM Professionals AS T1 JOIN Dogs AS T2 ON T1.professional_id = T2.professional_id WHERE T2.name = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"veterinary\" UNION SELECT first_name FROM Professionals WHERE role_code = \"guardian\" EXCEPT SELECT FROM Dogs WHERE name LIKE \"%dog%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"Medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , role_code , email_address FROM professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Dogs AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM treatments AS T1 JOIN owners AS T2 ON T1.dog_id = T2.owner_id GROUP BY T1.dog_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T3.dog_id = T2.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t2.treatment_type_description FROM treatments AS t1 JOIN treatment_types AS t2 ON t1.treatment_type_code = t2.treatment_type_code WHERE t1.charge_type = 'health' AND t1.cost_of_treatment = (SELECT sum(cost_of_treatment) FROM treatments WHERE charge_type = 'health')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT t1.treatment_type_description FROM treatment_types AS t1 JOIN treatments AS t2 ON t1.treatment_type_code = t2.treatment_type_code GROUP BY t1.treatment_type_code ORDER BY sum(t2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.owner_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.owner_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , cell_number FROM professionals WHERE role_code = 'Veterinarian' GROUP BY professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.date_of_treatment LIKE \"%date%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.charge_amount , T2.treatment_type_description FROM charges AS T1 JOIN treatment_types AS T2 ON T1.charge_type = T2.treatment_type_code WHERE T1.charge_type = \"Healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM treatments", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.size_description FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T3.size_code = T1.size_code WHERE T1.date_adopted = '2023-07-07'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.size_description FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T2.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.abandoned_yn = '0'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T3.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id JOIN Breeds AS T3 ON T1.breed_code = T3.breed_code WHERE T3.breed_name = 'Puppies' ORDER BY T3.date_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = (SELECT breed_code FROM Breeds ORDER BY breed_name LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_arrived , date_departed FROM dogs WHERE dog_id IN (SELECT dog_id FROM treatments WHERE treatment_type_code = 'medical' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Health\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" UNION SELECT email_address FROM Professionals WHERE state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = 'P' AND date_of_treatment LIKE '%health%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = \"P\" AND T.date_of_treatment LIKE \"%healthcare%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = \"Puppies\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY date_arrived DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments WHERE date_of_treatment = (SELECT max(date_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE first_name = \"guardian\" AND NOT IN (SELECT dog_id FROM dogs WHERE breed_code = \"Puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN (SELECT owner_id FROM dogs WHERE breed_code = 'Puppy')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN (SELECT professional_id FROM treatments WHERE dog_id = 'puppy')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = 'Veterinarian' EXCEPT SELECT count(*) FROM treatments WHERE dog_id IN (SELECT dog_id FROM dogs WHERE gender = 'Puppy')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE breed_code = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE breed_code = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs WHERE name = 'Puppy' ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs WHERE name = 'Puppy' ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM charges", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , home_phone , cell_number FROM Professionals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name , T2.size_description", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T2.breed_name , T2.size_description FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code JOIN sizes AS T3 ON T1.size_code = T3.size_code WHERE T1.age < 3 AND T1.gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.treatment_type_description FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.date_of_treatment = '2023-04-05'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer WHERE Citizenship = \"Vocalist\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY net_works_millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT count(*) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT country FROM singer WHERE position = 'Vocalist' GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT country FROM singer WHERE citizenship = 'MSA' GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_workillions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(networth Millions) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.name , sum(T1.sales) FROM song AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT name FROM singer WHERE singer_id NOT IN (SELECT singer_id FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT t2.feature_type_name FROM other_available_features AS t1 JOIN ref_feature_types AS t2 ON t1.feature_type_code = t2.feature_type_code WHERE t1.feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T2.property_type_description FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'house' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..63d1efaf4c8528efa2cdff0ac14f5f87f9af181a --- /dev/null +++ b/infer/qwen/spider_syn/sfkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , state FROM state_musician GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , highest FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.Stadium_ID , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T2.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t2.capacity FROM stadium AS t1 JOIN singer_in_concert AS t2 ON t1.stadium_id = t2.stadium_id JOIN concert AS t3 ON t2.concert_id = t3.concert_id WHERE YEAR >= 2014 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.year FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T1.year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium EXCEPT SELECT T1.name FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.Name , T2.Theme , COUNT(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T2.Theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T1.singer_ID = T3.singer_ID GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T3.name , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT t1.name , t1.position FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT t1.name , t1.position FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE t2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets WHERE pet_age = (SELECT min(pet_age) FROM Pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pet_type FROM Pets WHERE pettype = \"domestic\" GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.F = \"F\" AND T1.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' AND T2.pettype = \"Pug\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets AS T1 JOIN has_pet AS T2 ON T1.petid = T2.petid WHERE T1.pettype = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pettype) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" OR T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Pets WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet AS PetID JOIN Pets AS T1 ON T1.PetID = T1.PetID WHERE T1.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1.Fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Has_Pet WHERE PetType = \"dog\") EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID IN (SELECT PetID FROM Has_Pet WHERE PetType = \"kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT T2.pettype , T2.weight FROM Has_pet AS T1 JOIN Pets AS T2 ON T1.petid = T2.petid WHERE T1.petage = (SELECT min(petage) FROM pets)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(age) , max(age) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pettype , avg(weight) FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Mammal\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Fname = \"Tom\" AND T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T2.StuID FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.Fname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM has_pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex , T2.PetID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T2.PetID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3 AND T2.PetID = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.Continent GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT t1.contid , t1.continent , count(*) FROM continents AS t1 JOIN countries AS t2 ON t1.contid = t2.contid GROUP BY t1.continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(DISTINCT continent) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , COUNT(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.MakeId ORDER BY T2.Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.MPG < (SELECT avg(MPG) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT t1.fullName FROM car_makers AS t1 JOIN model_list AS t2 ON t1.id = t2.maker JOIN cars_data AS t3 ON t2.model = t3.model WHERE t3.year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker JOIN cars_data AS T3 ON T2.Model = T3.Model WHERE T3.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Make , T1.year FROM cars_data AS T1 JOIN car_names AS T2 ON T1.id = T2.makeid ORDER BY T1.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t1.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.id ORDER BY t2.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Maker = T2.Maker WHERE T2.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Maker = T2.Maker WHERE T2.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , count(*) FROM car_makers AS T1 JOIN continents AS T2 ON T1.Country = T2.Continent GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.ContId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.StateName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.CountryName ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.Continent FROM car_makers AS t1 JOIN continents AS t2 ON t1.Country = t2.CountryId GROUP BY t1.Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T2.Accelerate FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Model = T2.MakeId WHERE T1.Maker = \"Amc Hornet Sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.Accelerate FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model WHERE T3.Maker = 'Honda' AND T3.Model = 'Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullName LIKE \"%French%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryname WHERE T2.continent = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN countries AS T3 ON T3.countryid = T1.country WHERE T3.countryname = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(mpg) FROM cars_data WHERE cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT Weight FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT DISTINCT T1.Maker , T1.Model FROM car_makers AS T1 JOIN car_names AS T2 ON T1.Make = T2.Make", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.Continent , T1.Id FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id GROUP BY T1.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.Continent FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.ContId JOIN car_makers AS T3 ON T2.CountryId = T3.Country WHERE T3.Maker = \"Toyota\" GROUP BY T1.Continent HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.FullName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE cylinders = 3 GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T2.cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.MPGas = (SELECT max(MPG) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(T2.Edispl) FROM car_names AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T1.Maker = 'Volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT accelerate , cylinders FROM cars_data GROUP BY cylinders ORDER BY max(accelerate) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t2.Model FROM car_names AS t1 JOIN model_list AS t2 ON t1.Model = t2.Model WHERE t1.Make = \"Make\" GROUP BY t1.Make ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model GROUP BY T1.Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullName = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM car_names AS T1 JOIN cars_data AS T2 ON T1.MakeId = T2.MakeId WHERE T2.Weight > 3500 OR T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.FullName = \"General Motors\" UNION SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN car_names AS T2 ON T1.Model = T2.Model WHERE T2.MPG > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT max(Cylinders) FROM cars_data WHERE Make = 'Volvo' AND accelerate = (SELECT min(Accelerate) FROM cars_data WHERE Make = 'Volvo')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Accelerate = (SELECT min(Accelerate) FROM cars_data) AND MAKE = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(alculate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT country) FROM car_makers GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId WHERE T1.Cylinders = 4 ORDER BY T1.Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE id NOT IN (SELECT makeid FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data WHERE cylinders > 3))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE horsepower != \"min\" GROUP BY makeid HAVING count(*) < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight > 3500 EXCEPT SELECT T1.Model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.MakeId WHERE T2.FullName = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.MakeId WHERE T2.fullname = \"Ford Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T1.Continent FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent WHERE T2.CountryName NOT IN (SELECT T1.CountryName FROM cars_data AS T3 JOIN car_names AS T4 ON T3.MakeId = T4.ModelId GROUP BY T4.ModelId HAVING count(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T1.Continent FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.ContId EXCEPT SELECT T3.CountryName FROM cars_data AS T3 JOIN car_makers AS T4 ON T3.MakeId = T4.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.id = T2.Model GROUP BY T1.id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Maker = T2.Maker WHERE T2.Model = 'fiat' GROUP BY T1.Maker HAVING count(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Maker = T2.Maker WHERE T2.Model = 'fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Ford\" INTERSECT SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"BMW\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM state AS T1 JOIN airlines AS T2 ON T1.State = T2.Abbreviation WHERE T2.Abbreviation = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairportcode JOIN airlines AS T3 ON T3.Airline = T2.airline WHERE T3.Abbreviation = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T2.AirportName , T1.Airway FROM airlines AS T1 JOIN airports AS T2 ON T1.AirportCode = T2.AirportCode WHERE T1.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirwayName , T1.Abbreviation FROM airports AS T1 JOIN airlines AS T2 ON T1.AirportCode = T2.AirportCode WHERE T2.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT airportcode , airportname FROM airports WHERE city = 'Anthony'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM (SELECT airportcode FROM airports INTERSECT SELECT airportcode FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(T1.AirportCode) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.destairportcode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.airline = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines JOIN airports ON airlines.abbreviation = airports.airportcode WHERE country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT T1.AirportName , T1.Country FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T2.FlightNo = 16231", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , CountryAbbrev FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT T2.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.AirportCode WHERE T1.AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT airportname FROM airports WHERE city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.countryabbreviation = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.AirportCode = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = \"Terminal ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 'ABC' AND T1.destinationairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\" AND T2.destairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN (airlines AS T2 ON T1.airline = T2.airline WHERE T2.Abbreviation = 'JetBlue Airways') ON T1.airline = T2.airline", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.airline WHERE T2.Abbreviation = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Abbreviation = \"United Airlines\" AND T2.destairport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ASY Airport\" AND T1.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.Uid WHERE T2.Abbreviation = 'United' AND T1.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T1.airline = T3.UID WHERE T2.airportname = \"AHD\" AND T3.Abbreviation = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = 'Aberdeen' AND T1.airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"Aberdeen\" JOIN airlines AS T3 ON T3.UIL = T1.airline WHERE T3.Abbreviation = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN Flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T2.SourceAirport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.DestAirport ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T2.State FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T2.State ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.AirportCode FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.DestAirport GROUP BY T1.Abbreviation ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airway FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airways AS T1 JOIN flights AS T2 ON T1.airway = T2.destairport WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT DISTINCT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T1.airportcode = T3.airportcode WHERE T1.airportname = 'APG' INTERSECT SELECT DISTINCT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN airports AS T3 ON T1.airportcode = T3.airportcode WHERE T1.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport JOIN airports AS T3 ON T3.airportcode = T2.sourceairport WHERE T2.airline = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport JOIN airports AS T3 ON T3.airportcode = T3.airportcode WHERE T2.airline = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'CVO' EXCEPT SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T1.AirportName = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.airline WHERE T2.destairport = 'CVO' EXCEPT SELECT T1.airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.airline WHERE T2.destairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode HAVING sum(count(*) ) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FLIGHTNO FROM flights AS T1 JOIN airports AS T2 ON T1.DESTairport = T2.Airportcode WHERE T2.airportname = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.Airline , T1.FlightNo FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.SourceAirport WHERE T1.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"Aberdeen\" OR T2.AirportName = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DestAirport FROM flights , SELECT SourceAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , district FROM employee GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , district FROM employee GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN town AS T2 ON T1.city = T2.city GROUP BY T2.city HAVING avg(age) > 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , district FROM shop GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.district FROM shop AS T1 JOIN employee AS T2 ON T1.manager_name = T2.employee_id GROUP BY T1.manager_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM shop GROUP BY name ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , city FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T1.is_full_time = 'Yes' ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T2.Name FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID WHERE T1.Bonus = (SELECT max(Bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT Name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T3.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id JOIN evaluation AS T3 ON T1.employee_id = T3.employee_id WHERE T1.is_full_time = 'Y' ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T3.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id JOIN evaluation AS T3 ON T1.employee_id = T3.employee_id WHERE T1.is_full_time = 'Y' ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE manager_name NOT IN (SELECT DISTINCT manager_name FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T3.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id JOIN T3 AS evaluation ON T1.employee_id = T3.employee_id WHERE T1.is_full_time = 'Yes' GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT count(*) , T3.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id JOIN evaluation AS T3 ON T1.employee_id = T3.employee_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM hiring AS T1 JOIN evaluation AS T2 ON T1 = T2.Employee_ID WHERE T1.Start_from > 2020", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM hiring AS T1 JOIN evaluation AS T2 ON T1 = T2.Employee_ID WHERE T1.year_awarded = 2023", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT district) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Papers", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.template_id , T1.title , T1.description FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.Paragraph_ID , T1.paragraph_text , T1.document_description FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_name , T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE \"%w%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.paper_id , t1.layout_id , t2.template_details FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t3.document_id , t3.layout_id , t2.document_description FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id JOIN Templates AS t3 ON t1.template_id = t3.template_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Paragraphs AS T3 ON T3.paragraph_id = T2.paragraph_id WHERE T1.paragraph_text LIKE '%text%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Templates AS T2 ON T1.document_id = T2.template_id WHERE T2.template_type_code = 'PPT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Templates WHERE Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Paragraphs GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , layout_id FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.paragraph_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paragraph_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id JOIN Paragraphs AS T3 ON T2.paragraph_id = T3.paragraph_id WHERE T2.document_name = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM documents EXCEPT SELECT t1.template_id FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t2.paragraph_text = 'layout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.template_id , T2.version_number , T3.template_type_description FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code JOIN Templates(T3) ON T1.template_id = T3.template_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT layout FROM layout", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM templates AS t1 JOIN ref_template_types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM Ref_layouts WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type_name FROM Layouts WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , t2.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(version_number) , template_type_code FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_details = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t3.layout_type_code FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id JOIN templates AS t3 ON t1.template_id = t3.template_id WHERE t2.paragraph_text = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE \"%BK%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT t1.document_name FROM Documents AS t1 JOIN Templates AS t2 ON t1.template_id = t2.template_id WHERE t2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.template_type_description , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , layout_type FROM Ref_templates AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.layout_type FROM Paragraphs AS t1 JOIN Templates AS t2 ON t1.document_id = t2.template_id GROUP BY t1.layout_type ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM paragraphs AS T1 JOIN templates AS T2 ON T1.template_id = T2.template_id WHERE t1.paragraph_text = \"text\" GROUP BY t2.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_code FROM Ref_Template_Types EXCEPT SELECT DISTINCT template_type_code FROM Documents AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.type = \"text\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_code FROM templates EXCEPT SELECT DISTINCT template_type_code FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Paragraphs AS T3 ON T1.paragraph_id = T3.paragraph_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.template_type_description , T2.template_type_name FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.template_type_description , T2.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.layout_type_description FROM ref_template_types AS t1 JOIN your_table AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_Description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.template_type_description FROM ref_template_types AS t1 JOIN (SELECT template_type_code FROM templates GROUP BY template_type_code) AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.template_type_code JOIN Documents AS t3 ON t2.document_id = t3.document_id WHERE t3.document_name = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN Documents AS t3 ON t2.template_id = t3.template_id JOIN Paragraphs AS t4 ON t3.document_id = t4.document_id WHERE t4.paragraph_text LIKE \"%text file%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM Ref_Template_Types WHERE template_type_description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Summer Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM Paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Welcome to NY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT paragraph_id , paragraph_text FROM Paragraphs WHERE paragraph_text = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT DISTINCT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT t1.paragraph_text FROM paragraphs AS t1 JOIN documents AS t2 ON t1.document_id = t2.document_id WHERE t2.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.template_id , T1.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.paragraph_id , T1.paragraph_text , count(*) FROM Paragraphs AS T1 GROUP BY T1.paragraph_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT document_id , other_details FROM Paragraphs GROUP BY document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT paragraph_id FROM Paragraphs GROUP BY paragraph_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT T1.paragraph_id FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text LIKE '%Brazil%' INTERSECT SELECT document_id FROM paragraphs WHERE paragraph_text LIKE '%Ireland%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Brazil' INTERSECT SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Hometown FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT max(Staring_Date) FROM course", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T1.Hometown FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T3.Faculty , T2.Course_ID FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T3.Faculty , T2.Course_ID FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T3.Course_ID WHERE T3.课程 = 'math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T3.Course_ID = T1.Course_ID WHERE T3.Course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , count(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.teacher_id = T2.teacher_id GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Course_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Course_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE level_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_OF_MEMBERSHIP FROM visitor WHERE LEVEL_OF_MEMBERSHIP > 4 ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT Open_Year , Num_of_Staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.museum_id , T2.name , T2.level_of_membership FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_ID GROUP BY T2.museum_id ORDER BY sum(T2.total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Museum_ID , T2.name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit GROUP BY visitor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT T2.Total_spent FROM visitor AS T1 JOIN visit AS T2 ON T1.visitor_ID = T2.visitor_ID WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN ( SELECT T2.visitor_id FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id WHERE T1.num_of_ticket > 10000 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_date != \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_date = '2023-04-15'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , last_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT loser_age , winner_age FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches WHERE winner_rank != \"draw\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2013 INTERSECT SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.state_abbr FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T2.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT player_id , first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.state_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.state_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T1.winner_rank_points FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT t1.winner_name FROM players AS t1 JOIN matches AS t2 ON t1.player_id = t2.winner_id WHERE t2.tourney_name = \"Australian Open\" ORDER BY t2.winner_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\" ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT loser_name , winner_name FROM matches ORDER BY sum(minutes) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY sum(minutes) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(T1.ranking_points) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.ranking_points FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM players GROUP BY state_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.abbr FROM states AS T1 JOIN matches AS T2 ON T1.country_code = T2.loser_country GROUP BY T1.abbr ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY winner_age ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"right\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(id) , min(id) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T1.id , T1.disposition_of_ship FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T1.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.id WHERE T2.latin_commander = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT T1.id FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.id WHERE T1.tonnage = 225 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.id WHERE T1.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.id WHERE T1.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM addresses WHERE line_1 = 'Line 1' OR line_2 = 'Line 2'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM COURSES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT DISTINCT T1.course_description FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id JOIN Courses AS T3 ON T2.course_id = T3.course_id WHERE T3.department_id = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port\" AND department_name = \"Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = 'Port Chelsea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.department_id FROM departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_program_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_program_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM degree_programs AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id WHERE T2.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM degree_programs WHERE department_id IN (SELECT department_id FROM degree_programs WHERE department_name = 'Engineering')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT T1.section_name , T1.section_description FROM sections AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.semester_name , T1.student_id FROM student_enrolment AS T1 JOIN semesters AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT T2.department_description FROM courses AS T1 JOIN departments AS T2 ON T1.course_id = T2.course_id WHERE T1.course_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT DISTINCT T2.department_description FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T2.first_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Double Major' GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Undergraduate' GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T2.degree_program_id IN ( SELECT degree_program_id FROM degree_programs WHERE degree_summary_name = 'Bachelor\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Bachelor’s\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.degree_program_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T2.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T2.degree_program_id = T1.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T2.student_id , COUNT(*) FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T2.student_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T1.semester_name FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id EXCEPT SELECT T3.semester_name FROM semesters AS T3 JOIN student_enrolment_Courses AS T4 ON T3.semester_id = T4.semester_id JOIN courses AS T5 ON T4.course_id = T5.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id JOIN student_enrolment_courses AS T3 ON T2.course_id = T3.course_id GROUP BY T1.course_id HAVING count(*) > 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id JOIN student_enrolment_courses AS T3 ON T2.section_id = T3.section_id GROUP BY T1.course_name HAVING count(*) > 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id JOIN degree_programs AS T3 ON T3.degree_program_id = T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN students AS T3 ON T3.permanent_address_id = T2.address_id WHERE T2.state_province_county = \"North Carolina\" EXCEPT SELECT T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM students AS T1 JOIN student_enrolment_courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN courses AS T3 ON T2.course_id = T3.course_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T2.semester_id = 1 AND T2.degree_program_id = 'Graduate' ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id EXCEPT SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 , count(*) FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered FROM students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , transcript_id FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(T2.transcript_date) FROM transcripts AS T1 JOIN students AS T2 ON T1.transcript_id = T2.transcript_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , max_id FROM student_enrolment_courses GROUP BY max_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT max(count(*)), T1.course_id FROM Student_Enrolment_Courses AS T1 JOIN courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_course_id GROUP BY T2.student_course_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Student_Enrolment AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.degree_summary_name = 'Master' INTERSECT SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.degree_summary_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.degree_summary_name = 'Masters' INTERSECT SELECT T2.semester_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.address_id) FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T2.department_name FROM students AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM students ORDER BY first_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = 'h'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' OR T1.cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id JOIN students AS T3 ON T1.student_id = T3.student_id WHERE T2.country = \"Haiti\" OR T3.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM tv_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM tv_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM tv_channel WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM tv_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM tv_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T2.Channel , T1.Series_name FROM Cartoon AS T1 JOIN TV_Channel AS T2 ON T1.Channel = T2.id WHERE T1.Title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t1.id , t1.series_name FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Title FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.Episode , T1.Rating FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.channel = T2.channel ORDER BY T1.Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.episode FROM cartoon AS T1 JOIN TV_series AS T2 ON T1.channel = T2.channel WHERE T1.Content = \"A Love of a Lifetime\" AND T2.Rating = 18_49_Rating_Share", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Weekly_Rank FROM TV_series AS T1 JOIN (SELECT id , Episode FROM TV_series ORDER BY Weekly_Rank DESC LIMIT 1) AS T2 ON T1.episode = T2.episode WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Channel FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Series_name FROM TV_channel AS T1 JOIN tv_series AS T2 ON T1.id = T2.channel WHERE T2.Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Episode FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T1.Series_Name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM tv_channel WHERE Content = \"HD TV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , TV_Channel.id FROM TV_channel WHERE Hight_definition_TV = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Animation\" AND t2.write_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T2.PIXEL_aspect_ratio_PAR = \"Animated\" JOIN tv_series AS T3 ON T2.channel = T3.channel WHERE T3.18_49_Rating_Share = \"Great\" AND T1.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT T1.State FROM country AS T1 JOIN tv_channel AS T2 ON T1.id = T2.Channel WHERE T2.Content != 'Animation' AND T2.directed_by != 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.id , t1.Channel FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Ben Jones\" INTERSECT SELECT t1.id , t1.Channel FROM TV_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.id WHERE t2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Ben Jones\" INTERSECT SELECT t1.series_name , t1.country FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel WHERE country = 'United States' GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT Channel FROM cartoon EXCEPT SELECT Channel FROM cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM tv_channel EXCEPT SELECT T1.package_Option FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM tv_channel EXCEPT SELECT t1.package_option FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE height > 1.703 AND nationality = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE height > 1.705", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT FINAL_TABLE_MADE , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Nationality = \"Car\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE Nationality = \"Car Gammer\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(T1.Final_Table_Made) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings < 200000 AND T2.Nationality = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Finish = \"Top\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Finish = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT money_rank FROM people WHERE height = (SELECT max(height) FROM people)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Best_Finish = \"Game\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Earnings = \"Top 10\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM AREA_CODE_STATE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS EXCEPT SELECT contestant_name FROM CONTESTANTS WHERE contestant_name = 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT state , created FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T2contestant_number , T2contestant_name FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T2contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T2.contestant_number , T2.contestant_name FROM votes AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.area_code_state FROM votes AS T1 JOIN AREA_CODE_STATE AS T2 ON T1.state = T2.state GROUP BY T1.state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.set_up_date , T1.state , T1.phone_number FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number IN (SELECT T3.contestant_number FROM voters AS T3 WHERE T3.contestant_name = 'Tabatha Gehling')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state JOIN CONTESTANTS AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state JOIN CONTESTANTS AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independeyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t1.SurfaceArea) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.Code = t2.CountryCode WHERE t2.Percentage = 100 AND t1.Continent = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Antarctica'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT T2.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code2 = T2.Percentage WHERE T1.name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN country AS t2 ON t1.code = t2.code WHERE t1.name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE continent = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Continent = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , COUNT(*) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Angola\" GROUP BY T1.Region", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Region , count(*) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\" GROUP BY T1.Region", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(_life_expectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country ORDER BY lifeexpectancy LIMIT 1 AND continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(t1.population) , max(t2.gnp) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Region = \"Africa\" AND T2.GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Africa' AND governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE name = 'Asia' OR name = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE continent = 'Asia' OR continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT Population FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE governmentform = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE Region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT T2.Language) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE country.code = 'AFG' AND isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.State FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE Percentage = 100 AND Language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE Percentage = 100 AND Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"English\" INTERSECT SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.State FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" INTERSECT SELECT T1.State FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.State FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.State FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name , T2.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name , T2.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.IsOfficial = 1 AND T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = \"Republic\" GROUP BY T1.Language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT l1.language FROM country AS l1 JOIN countrylanguage AS l2 ON l1.code = l2.countrycode JOIN country AS l3 ON l2.countrycode = l3.code WHERE l3.region = 'Republic' AND l3.govformation = 'Yes' GROUP BY l1.language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.countrycode WHERE T2.Language = \"English\" GROUP BY T1.name ORDER BY sum(T1.population) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.countrycode = T2.CountryCode WHERE T2.Language = \"English\" GROUP BY T1.name ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.Population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code = T2.code WHERE T1.Continent = \"Asia\" ORDER BY T1.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.Population , T1.LifeExpectancy FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" ORDER BY T1.Population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE IsOfficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE IsOfficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = 'United Nations' AND T2.isofficial = 1 AND T1.indepyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT IsOfficial) FROM countrylanguage WHERE independyyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent != 'Asia' INTERSECT SELECT name FROM city WHERE population < (SELECT min(population) FROM city WHERE continent != 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent != 'Asia' GROUP BY countrycode HAVING population < (SELECT min(population) FROM country WHERE continent != 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT name FROM country WHERE population > (SELECT max(population) FROM country WHERE region = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' INTERSECT SELECT name FROM country WHERE population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode EXCEPT SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 1 AND T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT state FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.NationAbbr FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode EXCEPT SELECT T1.NationAbbr FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.NationCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.Code2 FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" EXCEPT SELECT T1.code2 FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode WHERE T2.Language = \"English\" AND T1.GovernmentForm != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT abbr FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"North Atlantic\" AND T1.GovernmentForm = \"Democratie\" AND T2.IsOfficial = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.CountryCode WHERE T3.IsOfficial = 0 AND T2.name NOT IN (SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Europe\" EXCEPT SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.name = \"China\" AND T3.Language = \"Chinese\" AND T2.Continent = \"Asia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"Asia\" INTERSECT SELECT DISTINCT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.IndepYear , T1.Territory FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code ORDER BY T2.Population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.Name , T1.Capital , T2.Code FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T2.Name , T2.Population , T2.HeadOfState FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode HAVING COUNT(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT T1.GovernmentForm , count(*) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Capital GROUP BY T1.GovernmentForm HAVING avg(T1.LiveExpectancy) > 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT T1.GovernmentForm , count(*) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Capital GROUP BY T1.GovernmentForm HAVING avg(T2.Population) > 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) , continent FROM country GROUP BY continent HAVING avg(lifeexpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT T1.Continent , sum(T2.Population) , avg(T2.LifeExpectancy) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code GROUP BY T1.Continent HAVING avg(T2.LifeExpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , region FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Europe\" AND T2.Population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.territory) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.territory > 3000 GROUP BY t2.code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t2.population > 3000 GROUP BY t2.code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.population >= 1600000 AND T2.population <= 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.State FROM countrylanguage AS T1 JOIN state AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T2.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.nationabbr , T2.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(t1.Percentage) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.CountryCode = t2.Code WHERE t1.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT countrycode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY countrycode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.State , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor WHERE YEAR_of_work = (SELECT max(yEAR_of_work) FROM conductor) ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE role = 'Director' GROUP BY name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.major_record_format FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID JOIN performance AS T3 ON T2.Orchestra_ID = T3.Orchestra_ID WHERE T3.Type = \"Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.major_record_format FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id JOIN performance AS T3 ON T2.orchestra_id = T3.orchestra_id WHERE T3.type = \"Show\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT t1.name FROM conductor AS t1 JOIN orchestra AS t2 ON t1.conductor_id = t2.conductor_id WHERE t2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , COUNT(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT T1.name , count(*) FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT T1.record_company FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.record_company ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT Major_record_format FROM orchestra GROUP BY Major_record_format ORDER BY COUNT(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra != 'none'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID JOIN show AS T3 ON T2.Performance_ID = T3.Performance_ID WHERE T1.year_of_founded < 2003 INTERSECT SELECT T1.Record_Company FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID JOIN show AS T3 ON T2.Performance_ID = T3.Performance_ID WHERE T1.year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE major_record_format = \"CD\" OR major_record_format = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE ID = (SELECT id FROM friend WHERE student_id = (SELECT id FROM likes WHERE liked_id = 'Kyle') )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM FRIEND GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = (SELECT id FROM friend WHERE student_id = 'Kyle' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 40576", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friends", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friends", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT T1.id FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id GROUP BY T1.id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) > 1 INTERSECT SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT DISTINCT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING max(T1.grade) > 5 INTERSECT SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2 AND T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = 'guardian' INTERSECT SELECT state FROM Professionals WHERE role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = \"guardian\" INTERSECT SELECT state FROM Professionals WHERE role_code = \"veterinary\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'Medical'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.treatment_type_code = \"health care\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Indiana\" OR T1.cell_number > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM OWNERS AS T1 JOIN PROFESSIONALS AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T1.owner_id , T1.last_name , T1.cell_number FROM OWNERS AS T1 JOIN PROFESSIONALS AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = \"Veterinary\" GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"veterinarian\" EXCEPT SELECT first_name FROM Professionals WHERE role_code = \"dog name\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"veterinarian\" EXCEPT SELECT first_name FROM Professionals WHERE role_code = \"dog name\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T3.dog_id = T2.dog_id WHERE T3.gender = \"dog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Owners AS T2 ON T1.professional_id = T2.professional_id EXCEPT SELECT T3.professional_id , T3.role_code , T3.email_address FROM Professionals AS T3 JOIN Treatments AS T4 ON T3.professional_id = T4.professional_id JOIN Dogs AS T5 ON T4.dog_id = T5.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.owner_id FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN vets ON T1.professional_id = T2.professional_id JOIN (SELECT professional_id FROM Treatment_Types GROUP BY professional_id HAVING count(*) >= 2) AS T2 ON T2.professional_id = T1.professional_id UNION SELECT T1.professional_id , T1.role_code , T1.first_name , T1.last_name FROM Professionals AS T1 JOIN vets ON T1.professional_id = T2.professional_id JOIN (SELECT professional_id FROM Treatment_Types GROUP BY professional_id HAVING count(*) >= 2) AS T2 ON T2.professional_id = T1.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM Dogs AS T1 JOIN Breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Professionals AS T3 ON T2.professional_id = T3.professional_id WHERE T3.role_code = 'Triage' GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.guardian_id , T2.first_name , T2.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T3.dog_id = T2.dog_id GROUP BY T1.guardian_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.cost_of_treatment = (SELECT cost_of_treatment FROM treatments GROUP BY cost_of_treatment ORDER BY sum(cost_of_treatment) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id GROUP BY T1.breed_name ORDER BY sum(T2.cost_of_treatment) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.gender = 'M' GROUP BY T1.owner_id ORDER BY sum(T3.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.guardian_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.guardian_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2 AND T2.treatment_type_code = 'Health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T3.professional_id = T2.professional_id WHERE T3.date_of_departed > '2021-01-01' AND T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_birth , T2.first_name FROM Dogs AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T2.role_code = \"operating\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM charges AS T1 JOIN treatment_types AS T2 ON T1.charge_type = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_charge , T3.treatment_type_description FROM charges AS T1 JOIN treatments AS T2 ON T1.charge_id = T2.treatment_type_code JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_description FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T4.size FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id JOIN Professionals AS T3 ON T2.professional_id = T3.professional_id JOIN Sizes AS T4 ON T1.size_code = T4.size_code WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.breed_name , T2.name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id WHERE T3.cost_of_treatment = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.breed_name , T1.date_of_departed FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.gender = 'dog' AND T2.date_of_departed LIKE '1999%' ORDER BY T2.date_of_departed DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T5.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN professionals AS T3 ON T2.professional_id = T3.professional_id JOIN treatment_types AS T4 ON T3.role_code = T4.treatment_type_code JOIN breeds AS T5 ON T5.breed_code = T1.breed_code WHERE T4.treatment_type_code = 'Medical' AND T5.breed_name = 'Rare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.name , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"VA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'Medical Care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'Health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" INTERSECT SELECT email_address FROM Professionals WHERE state = \"Wisconsin\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = 'Healthcare';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = \"healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.treatment_type_code = 'health' AND D.gender = \"P\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE D.gender = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT T2.role_code , T1.street , T1.city , T1.state FROM Owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM PROFESSIONALS WHERE city LIKE \"%West%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(t1.charge_amount) FROM charges AS t1 JOIN treatment_types AS t2 ON t1.charge_type = t2.charge_type_code WHERE t2.treatment_type_code = 'Health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments WHERE date_of_treatment = (SELECT date_of_treatment FROM treatments ORDER BY date_of_treatment LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE gender = \"P\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM treatment_types WHERE treatment_type_code = \"guardian\" EXCEPT SELECT count(*) FROM treatments WHERE dog_id IN ( SELECT dog_id FROM dogs WHERE weight < 100 AND gender = \"dog\" )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.gender = \"dog\" AND T2.breed_code != \"Puppy\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code != 'treatment'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = 'veterinary' AND professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = 'puppy')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'dog' AND breed_code = 'pu'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs WHERE breed_code = 'Pug'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM dogs WHERE gender = 'dog' ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM CHARGES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , sum(charge_amount) FROM CHARGES GROUP BY charge_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM PROFESSIONALS WHERE role_code = 'VETERINARIAN'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM PROFESSIONALS WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.age = \"dog\" AND T2.gender = \"pet\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN dogs AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_types AS T3 ON T3.treatment_type_code = T1.treatment_type_code WHERE T1.role_code = 'Veterinary'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.role_code , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT COUNT(*) , Citizenship FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.citizenship FROM singer AS t1 JOIN song AS t2 ON t1.singer_id = t2.singer_id GROUP BY t1.citizenship ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Country FROM singer GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(net_wealth_millions) , citizenship FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(networth) , country FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Title , T3.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID JOIN vocalist AS T3 ON T1.Name = T3.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT citizenship FROM singer WHERE birth_year < 1945 INTERSECT SELECT citizenship FROM singer WHERE birth_year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T2.property_type_description FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM Other_Property_Features WHERE property_id IN (SELECT property_id FROM Other_Property_Features WHERE apt_feature_1 = 'Yes' OR apt_feature_2 = 'Yes' OR apt_feature_3 = 'Yes')", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..5af63bd549624d2df8d38c18730846b0385ddc2c --- /dev/null +++ b/infer/qwen/spider_syn/sft_sft_qwen3_0.6b_spider__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , T1.state FROM states AS T1 JOIN singer AS T2 ON T1.state = T2.country GROUP BY T1.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT title FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT title FROM music WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT location , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium GROUP BY average(high) ORDER BY average(high) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T1.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T1.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year > 2013 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT TIME FROM concert GROUP BY TIME ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT state FROM singer WHERE age > 40 INTERSECT SELECT state FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.theme , count(*) FROM singer AS T1 JOIN concert AS T2 ON T1.song_id = T2.song_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T2.theme , count(*) , T3.name FROM singer AS T1 JOIN concert AS T2 ON T1.song_id = T2.song_id JOIN singer_in_concert AS T3 ON T1.song_id = T3.song_id GROUP BY T3.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.songer_id = T2.songer_id GROUP BY T2.songer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T2.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.songer_id = T2.songer_id GROUP BY T2.songer_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.songer_id = T2.songer_id JOIN concert AS T3 ON T2.cnt_id = T3.cnt_id WHERE T3.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T2.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.songer_id = T2.songer_id JOIN concert AS T3 ON T3.concert_id = T2.concert_id WHERE T3.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT T1.name , T1.country FROM singer AS T1 JOIN song AS T2 ON T1.song_name = T2.song_name WHERE T2.song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.location FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.high = (SELECT max(high) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM pets WHERE pet_type = 'K' ORDER BY age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT min(weight) FROM pets WHERE pettype = 'animal'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pet_type FROM pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pet_type FROM pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet AS T1 JOIN student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = 'F' AND T1.pettype = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM has_pet AS T1 JOIN student AS T2 ON T1.stuid = T2.stuid WHERE T2.sex = 'F' AND T1.pettype = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pet_type) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pet_type) FROM pets", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Cat\" OR T3.PetType = \"Duppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" OR T3.pettype = \"Pupdog\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Cat\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Duck\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" INTERSECT SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Pugma\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetType = \"Kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT discipline , age FROM Student EXCEPT SELECT T1.d discipline , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T2.PetID = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"Cat\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT fname FROM Student WHERE StuID IN (SELECT StuID FROM Has_Pet WHERE PetID = \"dog\" EXCEPT SELECT StuID FROM Has_Pet WHERE PetID = \"kitten\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , sum(weight) FROM pets GROUP BY pettype ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT StuID , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT StuID , weight FROM Pets WHERE pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(age) , max(age) , pet_type FROM Student GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(age) , max(age) FROM pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'animal'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"animal\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT petid FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID WHERE T2.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT petid FROM haspet AS T1 JOIN student AS T2 ON T1.StuID = T2.StuID WHERE T2.LName = 'Smith'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T2.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T2.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3 AND T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.stuid = T2.stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age = 3 AND T1.sex = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.Countid , T1.Countertname , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Countid = T2.Countid GROUP BY T1.Countid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.Countid , T1.CountryName , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Countid = T2.Countid GROUP BY T1.Countid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM states", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Fname , T1.Lname , T2.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.Name , COUNT(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT Model FROM cars_data WHERE Weight < (SELECT avg(Weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT T1.Fname FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Maker WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.Year FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.id ORDER BY T1.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T2.Maker , T1.Year FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Model ORDER BY T1.Year ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN model_list AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Countid , COUNT(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Countid", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Countinent , COUNT(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.Countinent = T2.Country GROUP BY T1.Countinent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.State FROM states AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.State FROM states AS T1 JOIN car_makers AS T2 ON T1.Country = T2.Country WHERE T2.Maker = (SELECT T2.Maker FROM car_makers GROUP BY T2.Maker ORDER BY COUNT(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.name FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1 FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.Accelerate FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Make = T2.Id JOIN model_list AS T3 ON T1.Model = T3.Model WHERE T2.Maker = \"Amc Hornet\" AND T3.Sporting = \"Sw\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT avg(T1.accelerate) FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.id = T2.id JOIN countries AS T3 ON T2.country = T3.countryid WHERE T3.countryname = 'Americano' AND T1.vehicle = 'Hornet'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE Country = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id JOIN countries AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE YEAR = 1974 AND cylinders = 8", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T2.Maker , T3.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id JOIN model_list AS T3 ON T1.Model = T3.Model", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T2.Maker , T1.Model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.State , T2.id FROM states AS T1 JOIN car_makers AS T2 ON T1.Countertable = T2.Country WHERE T2.Maker != \"null\" GROUP BY T2.id HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.countryname , T1.state FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker != \"null\" GROUP BY T1.state HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.State FROM states AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T1.CountryName = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T2.Horsepower) , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.Maker WHERE T2.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(T2.Horsepower) , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.Cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY MPG DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(T1.EDISPL) FROM cars_data AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T2.Model = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE YEAR = 2004", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) , cylinders FROM cars_data GROUP BY cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM model_list GROUP BY model ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM model AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.Id WHERE T2.Maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Fname , T1.Lower FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T2.maker HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T2.Maker , T1.id FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.id GROUP BY T1.id HAVING COUNT(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.type FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.weight > 3500 OR T1.fullname = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.Model = T2.Model WHERE T2.Weight > 3500 OR T1.Maker = \"General Motors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Cylinders) FROM cars_data WHERE model = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(Cylinders) FROM cars_data WHERE Model = \"volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers WHERE country = \"State\" GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM (SELECT T1.state , T2.id FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country GROUP BY T2.id HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE cylinders = 4 ORDER BY horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower DESC LIMIT 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , manufacturer FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data) EXCEPT SELECT T1.Makeid , T1.manufacturer FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.cylinders > 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , model FROM cars_data WHERE cylinder < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.maker = T2.id WHERE T2.Maker = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN car_makers AS T2 ON T1.Maker = T2.id WHERE T2.Maker != 'Ford Motor Company' AND T1.Model < 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.id GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.countryid , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE T2.Maker > 3 UNION SELECT T1.countryid , T1.countryname FROM countries AS T1 JOIN model_list AS T2 ON T1.countryid = T2.Maker WHERE T2.Model = 'fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.County > 3 UNION SELECT T1.id , T1.countryname FROM countries AS T1 JOIN cars_data AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"Fiat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Airline \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirportName , T1.AirportName LIKE \"%USA%\" FROM airlines AS T1 JOIN airports AS T2 ON T1.Airline = T2.AirportCode WHERE T2.Country = \"USA%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirwayName , T1.AirwayName FROM airlines AS T1 JOIN airports AS T2 ON T1.Airline = T2.AirportCode WHERE T2.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(Airline) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airlines", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.Airline LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE country = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT T1.City , T1.State FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport WHERE T1.AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , State FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SOURCE Airport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SOURCE Airport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATOT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'City Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Ebernthal\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = 'Aberdeen' AND destinationairport = 'Ashley'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = \"Aberdeen\" AND destinationairport = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"United Airlines\" AND T2.destairport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"United Airlines\" AND T2.destinationairport = \"ASY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"United Airlines\" AND T2.sourceairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = \"United Airlines\" AND T2.sourceairport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport WHERE T1.airline = 'United Airlines' AND T2.destairport = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.airline = \"United Airlines\" AND T2.sourceairport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT City FROM airports GROUP BY City ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T2.SourceAirport ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.AirportCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY COUNT(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.flights , T1.state_of_airway FROM airlines AS T1 JOIN flights AS T2 ON T1.airline = T2.source_airport GROUP BY T1.state_of_airway ORDER BY flights DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Airline , T1.Country FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport GROUP BY T1.Airline ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.Airline FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.sourceairport JOIN airports AS T3 ON T3.airportcode = T2.destairport WHERE T3.AirportName = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.Dest Airport = T2.AirportCode WHERE T2.AirportName = 'APG' INTERSECT SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.Dest Airport = T2.AirportCode WHERE T2.AirportName = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\" INTERSECT SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"CVO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT * FROM flights WHERE sourceairport = 'CVO' EXCEPT SELECT * FROM flights WHERE sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"CVO\" EXCEPT SELECT T1.Airline FROM flights AS T1 JOIN airports AS T2 ON T1.Dest Airport = T2.AirportCode WHERE T2.City = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airport FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode HAVING COUNT(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.Airport FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode HAVING COUNT(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airport FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode HAVING COUNT(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airport FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode HAVING COUNT(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.Airline = T2.FlightNo WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.Airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.flightno FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SOURCEAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.flightno FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.city = \"Aberdeen\" OR T1.city = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights) INTERSECT SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights) OR AirportCode NOT IN (SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , town FROM employee GROUP BY town", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , town FROM employee GROUP BY town", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT town FROM employee WHERE age < 30 GROUP BY town HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT town FROM employee WHERE age < 30 GROUP BY town HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , T1.city FROM employee AS T1 JOIN shop AS T2 ON T1.employee_id = T2.manager_name GROUP BY T1.city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.district FROM shop AS T1 JOIN employee AS T2 ON T1.manager_name = T2.employee_id GROUP BY T1.manager_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT T1.name , T1.city , T1.district FROM employee AS T1 JOIN shop AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT T1.name , T1.city , T1.district FROM employee AS T1 JOIN shop AS T2 ON T1.employee_id = T2.manager_name ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT T1.name FROM shop AS T1 JOIN evaluation AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id HAVING count(*) > (SELECT avg(count(*) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE T2.year_awarded = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T1.name , count(*) FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT store , count(*) FROM employee GROUP BY store", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T1.bonus) FROM assessment AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T1.bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM RefPaper", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Paper", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.paper_id , T1.paper_name , T1.paper_description FROM Papers AS T1 JOIN Ref_Template_Types AS T2 ON T1.paper_id = T2.paper_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.document_id , T1.paper_name , T1.document_description FROM Papers AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , other_details FROM Documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.paper_name , T2.layout_id FROM Papers AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T1.document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT T1.paper_id , T1.layout_id , T2.document_description FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT T1.paper_id , T1.layout_id , T2.Other_Details FROM Documents AS T1 JOIN Ref_Template_Types AS T2 ON T1.Document_ID = T2.Document_ID WHERE T1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT t2.formatter_text) FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Text File\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT T1.layout_id , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT count(*) , T1.layout_id FROM Layouts AS T1 JOIN Papers AS T2 ON T1.layout_id = T2.layout_id GROUP BY T1.layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.layout_id FROM layouts AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.layout_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM templates AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates EXCEPT SELECT template_id FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT T1.template_id FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code EXCEPT SELECT T1.template_id FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Papers AS T3 ON T1.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Ref/Layout", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Ref_LAYOUT", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.Template_ID , T2.Version_Number , T1.Template_Type_Code FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.Template_ID , T2.Version_Number , T3.Template_Type_Description FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID JOIN Ref_Template_Types AS T3 ON T2.Template_Type_Code = T3.Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT layout_type_name FROM ALL", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT T1.Template_ID FROMTemplates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T2.Template_Type_Description = \"PP\" OR T2.Template_Type_Description = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT T1.Template_ID FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T2.Template_Type_Description = \"PP\" OR T2.Template_Type_Description = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.Template_Type_Description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM CV", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T1.Edition_Number , T1.Template_Type_Description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.Edition_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T1edition_number , T2.template_type_name FROM Layouts AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Template_Type_Code , COUNT(*) FROM Ref_Template_Types GROUP BY Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT count(*) , Template_Type_Description FROM Ref_Template_Types GROUP BY Template_Type_Description", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types GROUP BY Template_Type_Code ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.type_name FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.type_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Template_Type FROM Ref_Template_Types GROUP BY Template_Type HAVING COUNT(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types GROUP BY Template_Type_Description HAVING COUNT(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Template_Type_Code) FROMTemplates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(VERSION_NUMBER) , min(Template_Type_Code) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.Template_Type_Code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Documents AS T3 ON T2.Template_ID = T3.Template_ID WHERE T3.document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T1.Template_Type_Code FROM Ref_Template_Types AS T1 JOIN Documents AS T2 ON T1.Template_Type_Code = T2.Template_ID WHERE T2.Document_name = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM Documents WHERE document_name LIKE \"%BK%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T1.paper_name FROM papers AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id JOIN templates AS T3 ON T2.template_id = T3.template_id WHERE T3.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.Template_Type_Description , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.Template_Type_Description", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , template_type_code FROM Ref_layout_types GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.layout_type_code FROM Ref_Template_Types AS T1 JOIN Paragraphs AS T2 ON T1.Template_Type_Code = T2.Document_ID GROUP BY T1.layout_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Template_Type_Code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.Template_Type_Code ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type FROM Ref_Template_Types EXCEPT SELECT DISTINCT t1.template_type FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.Template_Type_Code = t2.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types EXCEPT SELECT T1.Template_Type_Description FROM Ref_Template_Types AS T1 JOIN Paragraphs AS T2 ON T1.Template_Type_Code = T2.Document_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.Template_Type_Description , T2.Layout_Type_Name FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.Type_Name , T2.Template_Type_Description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT T2.Template_Type_Description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT T1.Type FROM Ref_Template_Types AS T1 JOINTemplates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.Template_Type_Description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT TYPE_CODE FROM Ref_Template_Types WHERE Template_Type_Description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Documents AS T3 ON T2.Document_ID = T3.Document_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T1.document_description FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.Template_ID = T3.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.Template_ID FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code WHERE T1.Template_Type_Description = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM layouts AS T1 JOIN ref_template_types AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_Description = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragrapths", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM PARAGRAPHs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID WHERE T1.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM paragraphs AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE Paragraph_Text = \"Korea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE Paragraph_Text LIKE \"%Korea%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T2.paragraph_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Welcome to NY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T2.para_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = 'Customer reviews'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT count(*) , T1.paper_id FROM papers AS T1 JOIN documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.paper_id ORDER BY T1.paper_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT paragraph_id , count(*) FROM Paragraphs GROUP BY paragraph_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.document_id , T1.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.document_id , T1.paper_id , count(*) FROM Papers AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.Template_ID FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.Document_ID = T2.Document_ID GROUP BY T1.Template_ID HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T1.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T1.paper_id FROM Papers AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT Paragraph_ID FROM Paragraphs GROUP BY Paragraph_ID HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT paper_id FROM paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT paper_id FROM paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.para_text = 'Brazil' INTERSECT SELECT T1.document_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.para_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT count(*) , Hometown FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Curriculum FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Curriculum FROM course AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name , T1.Course FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID ORDER BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID WHERE T1.Course = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT Name FROM visitor WHERE LEVEL_OF_membership > 4 ORDER BY LEVEL_OF_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE level_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT Name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE open_year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT open_year , num_of_staff FROM museum WHERE name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T1.id , T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T1.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name , T1.level_of_membership FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id ORDER BY sum(T2.total_spent) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Museum_ID , T1.Name FROM museum AS T1 JOIN visit AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(Num_of_Ticket) , max(Num_of_Ticket) FROM visit", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.total_expense) FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id WHERE T1.level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID WHERE T2.Opening_Year < 2009 INTERSECT SELECT T2.Name FROM visit AS T1 JOIN museum AS T2 ON T1.Museum_ID = T2.Museum_ID WHERE T2.Opening_Year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN ( SELECT visitor_id FROM visit WHERE open_year > 2010 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM participants", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winning_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winning_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM participants", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT T1.tourney_name FROM matches AS T1 JOIN rankings AS T2 ON T1.rankings = T2.player_id GROUP BY T1.tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT T2.tourney_name FROM competitions AS T1 JOIN matches AS T2 ON T1.matching_id = T2.matching_id GROUP BY T2.tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T2.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.statecode FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.last_name , T2.statecode FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , last_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.statecode FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.winery_NAME , T2.winery_RANK FROM MATCHES AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.winery_NAME ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T2.winner_rank , T2.winer_rank_points FROM MATCHES AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.rank = T3.rank WHERE T3.tours = 'Australian Open' ORDER BY T2.winery_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winery_NAME FROM MATCHES AS T1 JOIN players AS T2 ON T1.winery_ID = T2.player_id JOIN rankings AS T3 ON T1.rank = T3.rank WHERE T3.tourney_name = \"Australian Open\" ORDER BY T3.winery_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year DESC LIMIT 1 INTERSECT SELECT T2.first_name , T2.last_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id ORDER BY T1.year DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.rank) , T2.first_name , T2.last_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , avg(T2.rank) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.player_id , sum(T2.ranking_points) , T1.first_name , T1.last_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , sum(T2.ranking_points) FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , T1.state FROM states AS T1 JOIN matches AS T2 ON T1.state = T2.state GROUP BY T1.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , T1.state FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.ranking FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.nationality FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.nationality ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id GROUP BY T1.country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.player_id GROUP BY T1.country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_rank LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T2.winery_NAME , T2.winery_RANK FROM MATCHES AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winery_RANK ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T2.winner_id) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.tourney_name = \"WTA Championships\" AND T2.hand = \"left\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM left-handed players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T3.player_id = T2.player_id WHERE T3.tourney_name = \"WTA Championships\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.country_code , T1.birth_date FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.winning_rank DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T2.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , T1.hand FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , T1.hand FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , RESULT FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(toll) , min(toll) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T1.id , T1.injured FROM death AS T1 JOIN ship AS T2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type != 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2 killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM combats WHERE id NOT IN ( SELECT id FROM ship WHERE tonnage = 225 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE lost_in_battle NOT IN (SELECT T1.id FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.lost_in_battle WHERE T2.languages = 'english')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM addresses WHERE line_1 = \"1\" AND line_2 = \"2\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(DISTINCT course_name) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM COURSES WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT T1.course_description FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id JOIN courses AS T3 ON T2.course_id = T3.course_id WHERE T3.course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.department_name , T2.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T2.department_id ORDER BY sum(T1.degrees) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.department_name , count(*) FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T2.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_program_id) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(DISTINCT T1.degrees) FROM degree_programs AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id WHERE T2.department_name = \"Engineering\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(DISTINCT T1.degrees) FROM degree_programs AS T1 JOIN departments AS T2 ON T1.department_id = T2.department_id WHERE T2.department_name = \"Engineering\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM SECTION", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM SECTIONs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.section_name , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Sections AS T2 ON T1.section_id = T2.section_id GROUP BY T1.student_enrolment_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM semesters AS T1 JOIN student_enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT DISTINCT T1.department_description FROM departments AS T1 JOIN TRANSACTIONS AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT T1.department_description FROM departments AS T1 JOIN transcriptions AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name LIKE \"%computer%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name , T1.student_id FROM Student_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id WHERE T1.course_id IN (SELECT course_id FROM Degree_Programs WHERE degree_summary_name = \"2\") AND T1.semester_id IN (SELECT semester_id FROM Semesters WHERE semester_summary_name = \"1\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name , T1.student_id FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T1.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Undergraduate\" AND T1.semester_id = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T1.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Bachelor\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name FROM Student_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id WHERE T1.course_name = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.degree_summary_name FROM student_enrolment AS T1 JOIN degree_programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T2.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.program , T1.course_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.course_program_id = T2.course_program_id GROUP BY T1.program ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Student_Enrolment AS T1 JOIN Degree_Programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T2.first_name , T2.middle_name , T1.last_name , count(*) , T1.student_id FROM Student_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.middle_name , T2.last_name , T1.student_id , count(*) FROM Student_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT section_name FROM sections WHERE course_id NOT IN (SELECT course_id FROM Student_Enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT section_name FROM sections WHERE course_id NOT IN (SELECT course_id FROM Student_Enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT DISTINCT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT DISTINCT T1.course_name FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN student_enrolment AS T2 ON T1.address_id = T2.address_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN student_enrolment AS T2 ON T1.address_id = T2.address_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timothy\" AND last_name = \"Ward\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT T2.first_name FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.line_1 != T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id != (SELECT permanent_address_id FROM addresses)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.address_id , T1.line_1 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T2.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , other_student_details FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , other_details FROM TRANSACTIONS", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM STUDENTS", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM STUDENTS", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT last_name FROM Students ORDER BY date_left DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_left) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_enrolment_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T2.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.section_name FROM student_enrolment AS T1 JOIN sections AS T2 ON T1.section_id = T2.section_id WHERE T1.student_id = 'Master' INTERSECT SELECT T2.section_name FROM student_enrolment AS T1 JOIN sections AS T2 ON T1.section_id = T2.section_id WHERE T1.student_id = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.section_id FROM Student_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id WHERE T2.degree_program_id = 'MA' INTERSECT SELECT T1.section_id FROM Student_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id = T2.student_id WHERE T2.degree_program_id = 'BPh.D.'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.address_id) FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T1.address_id FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name , T2.middle_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.country = \"Haitt\" UNION SELECT T2.first_name , T2.middle_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T2.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name , T2.middle_name FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.city = \"Haiti\" UNION SELECT first_name , middle_name FROM Students WHERE cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM Cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM Cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT * FROM Cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT T2.title , T2.directed_by FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.air_date = T2.original_air_date ORDER BY T1.air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM Cartoon ORDER BY released_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT country , count(*) FROM TV_channel GROUP BY country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE LANGUAGE = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE LANGUAGE = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT LANGUAGE , COUNT(*) FROM TV_channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT LANGUAGE , COUNT(*) FROM TV_CHANNEL GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT LANGUAGE , COUNT(*) FROM TV_channel GROUP BY LANGUAGE", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT count(*) , language FROM TV_channel GROUP BY language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.series_name FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.series_name FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.channel WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.title FROM cartoon AS T1 JOIN tv_series AS T2 ON T1.channel = T2.channel JOIN tv_channel AS T3 ON T2.channel = T3.id WHERE T3.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT * FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT air_date FROM TV_series WHERE episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT weekly_rank FROM TV_series WHERE episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.Channel FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.serial_name FROM TV_channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.channel WHERE T2.Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM Cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM Cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_CHANNEL WHERE high_definition_tv = 'HD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT package_option , series_name FROM TV_channel WHERE high_definition_tv = 'HD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM TV_state AS T1 JOIN TV_series AS T2 ON T1.Channel = T2.Channel WHERE T2.Written_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT T1.country FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT state FROM cartoon EXCEPT SELECT DISTINCT T1.state FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.channel = T2.channel WHERE T2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.country FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T2.series_name , T2.country FROM Cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\" INTERSECT SELECT T2.series_name , T2.country FROM Cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT pixel_aspect_ratio_par , country FROM TV_CHANNEL WHERE language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT pixel_aspect_ratio_par , country FROM TV_CHANNEL WHERE language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel WHERE country = 'States' GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_channel EXCEPT SELECT T1.package_option FROM TV_channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM TV_CHANNEL EXCEPT SELECT T1.package_option FROM TV_CHANNEL AS T1 JOIN Cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(T2.Final_Table_Made) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T2.Birth_Date FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM People WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people EXCEPT SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Gameshowing is 'Car'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT created FROM votes WHERE state = 'CA' ORDER BY created DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name != 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT state , created FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T1.contestant_number , T1.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.contestant_number , T1.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T2.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM votes AS T1 JOIN area_code_state AS T2 ON T1.state = T2.state WHERE T2.state = 'NY' OR T2.state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.created , T1.state , T1.phone_number FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.comcontest_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 'Tabatha Gehling' INTERSECT SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT HeadOfState FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(*) FROM country WHERE governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.total_area) FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.district = \"State\" AND T1.region = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t1.area) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t1.region = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT T1.continent FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT DISTINCT region FROM city WHERE name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT region FROM city WHERE name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.name = 'Aruba' GROUP BY T1.language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE countrycode = 'Aruba'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.population , T1.lifeexpectancy FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.name = 'Brazil'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT GNP , LEX FROM country WHERE CountryCode = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.region , T2.population FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.name = \" Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.District , T1.Population FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \" Angola\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(lifeexpectancy) FROM country WHERE continent = 'Central Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND lifeexpectancy = (SELECT min(lifeexpectancy) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code ORDER BY t2.lifeexpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(max(gnp) FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.region = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(t1.lifespan) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t1.name = \"African\" AND t2.isofficial = \"R\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(t1.lifespan) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t2.region = 'Africa' AND t1.isofficial = 'R'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(t1.area) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t1.name = 'Asia' OR t1.name = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(t1.area) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t1continent = 'Asia' OR t1continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT count(*) FROM city WHERE district = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(gnp) FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.governorform = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , sum(gnp) FROM country WHERE continent = 'United States'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT gnp) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT gnp) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T1.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE countrycode = 'Afghanistan' AND isofficial = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.countrycode = 'Afghanistan' AND T2.isofficial = 'Yes'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode GROUP BY T3.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1 Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1 Continent ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country WHERE head_of_state = 'English' INTERSECT SELECT count(*) FROM country WHERE head_of_state = 'Dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"english\" INTERSECT SELECT count(*) FROM countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'English' INTERSECT SELECT T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'English' INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.clont) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1continent) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT T1.region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = 'english' OR T2.language = 'dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT T1.region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = 'Dutch' OR T2.language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 'English' OR T2.isofficial = 'Dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = \"English\" OR T2.IsOfficial = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T2.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.continent = \"Asia\" GROUP BY T2.language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.isofficial = 'A' GROUP BY T1.language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.isofficial = 'Yes' AND T2.region = 'Republic' GROUP BY T1.language HAVING count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT T1.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.governor = 'United Kingdom' INTERSECT SELECT T1.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.governor = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.language = 'english' GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T3.language = 'english' GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , lifeexpectancy FROM country WHERE countrycode = (SELECT countrycode FROM country ORDER BY population DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(t1.lifespan) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.isofficial = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(t1.lifespan) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.isofficial = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(t2.lifespan) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t1.language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE code NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"english\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.headofsstate = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T1.name = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(t1.count(DISTINCT t2.languages) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t1.indep_year < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(T1.GNP) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.IsOfficial = 'Yes' AND T1.GNP < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT min(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.region = 'Africa' AND T2.population < (SELECT max(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.region = 'Africa' AND T2.population < (SELECT min(population) FROM country WHERE continent = 'Asia')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T2.population > (SELECT min(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT HeadOfState FROM city WHERE Population > (SELECT max(Population) FROM city WHERE CountryCode = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT code FROM country EXCEPT SELECT T1.code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT HeadOfState FROM country WHERE Language != \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language != 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.GNP FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 'No' AND T1.GovernmentForm != 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT HeadOfState FROM country WHERE GovernmentForm = 'English' AND IsOfficial = 'No'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T2.isofficial = 'No' AND T3.language = 'english'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.countrycode WHERE T2.continent = 'Europe' AND T3.language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.region = 'Asia' AND T2.isofficial = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T2 Continent = \"Asia\" AND T3.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , founded_year , territory FROM country ORDER BY population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , founded_year , territory FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , head_of_state FROM country ORDER BY surfacearea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , head_of_state FROM country ORDER BY surface_area DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT gnp , count(*) FROM country WHERE lifeexpectancy > 72 GROUP BY gnp", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT sum(Population) , GNP FROM country WHERE avg(LifeExpectancy) > 72 GROUP BY GNP", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(T1.LifeExpectancy) , avg(T2.GNP) , T2 Continent FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code GROUP BY T2 Continent HAVING avg(T1.LifeExpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT sum(Population) , avg(LifeExpectancy) , continent FROM country GROUP BY continent HAVING avg(LifeExpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT T1.name , T1.SurfaceArea FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode ORDER BY T1.SurfaceArea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , region FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT headofstate FROM country WHERE continent = 'Europe' AND population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN city AS T2 ON T1.code = T2.countrycode WHERE T1.region = 'Europe' AND T2.population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.area) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t1continent = \"North America\" AND t1.area > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.area) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.name = 'North America' AND t1.area > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT Name FROM city WHERE Population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage ORDER BY population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T2.language , T1.HeadOfState FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T1.HeadOfState ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Name , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(t2.gnp) FROM country AS t1 JOIN countrylanguage AS t2 ON t1.code = t2.countrycode WHERE t2.language = \"Spanish\" GROUP BY t2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = \"Spanish\" GROUP BY T1.code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T2.code FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.language = 'Spanish' GROUP BY T2.code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM director", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM director", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM director WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM director WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY Year_of_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT director FROM director ORDER BY as director", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM director ORDER BY created_director DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY YEAR_of_Work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.ensemble FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.director FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.name FROM show AS T1 JOIN orchestra AS T2 ON T1.orchard_id = T2.orchard_id GROUP BY T2.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_work > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT record_company , count(*) FROM orchestra GROUP BY record_company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.name FROM enterprise AS T1 JOIN orchestra AS T2 ON T1.organchestra = T2.organchestra_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT record_type FROM orchestra GROUP BY record_type ORDER BY count(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM performance WHERE TYPE != \"Ensemble\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE YEAR_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE YEAR_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE YEAR_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1 Orchestra_ID = T2 Orchestra_ID GROUP BY T1.year_of_Founded HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.year_of_founded FROM performance AS T1 JOIN orchestra AS T2 ON T1.organchestra_id = T2.organchestra_id GROUP BY T1.organchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM Highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM Highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM Highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.student_id FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(T2.friend_id) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(T2.friend_id) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM student EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM student EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friends INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM friend INTERSECT SELECT student_id FROM likes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T2.name FROM friends AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friends AS T2 ON T1.id = T2.student_id INTERSECT SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T2.liked_id = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , student_id FROM likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) > 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2 AND T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2 AND T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(DISTINCT T1.interests) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T2.grade) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T2.grade) FROM friends AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.friend_id != \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT T1.state FROM professionals AS T1 JOIN guardians AS T2 ON T1.professional_id = T2.professional_id INTERSECT SELECT T1.state FROM professionals AS T1 JOIN veterinarians AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT T1.state FROM professionals AS T1 JOIN guardians AS T2 ON T1.professional_id = T2.professional_id INTERSECT SELECT T1.state FROM professionals AS T1 JOIN veterinarians AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treats AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'medical'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatment_tors AS T2 ON T1.dog_id = T2.dog_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.role_code = 'doctor' AND T2.treatment_type_description = 'health care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T2.professional_id , T2.last_name , T2.cell_number FROM treatment_profiles AS T1 JOIN physicians AS T2 ON T1.professional_id = T2.professional_id JOIN owners AS T3 ON T1.owner_id = T3.owner_id WHERE T3.state = 'Indiana' OR T1.cell_number > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T2.professional_id , T2.last_name , T2.cell_number FROM patients AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Indiana\" UNION SELECT T2.professional_id , T2.last_name , T2.cell_number FROM patients AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id GROUP BY T2.professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs EXCEPT SELECT T1.name FROM dogs AS T1 JOIN treatings AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treats AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM professionals WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT first_name FROM dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code != \"Medical\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code != 'health-care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T2.professional_id , T2.role_code , T2.first_name FROM treatments AS T1 JOIN physicians AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.dog_id , T1.family_name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id GROUP BY T1.dog_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.last_name FROM owners AS T1 JOIN treatments AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T2.cost_of_treatment = (SELECT min(cost_of_treatment) FROM Treatments WHERE T2.cost_of_treatment = 'health-care')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM treatment_types AS T1 JOIN treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code ORDER BY T2.cost_of_treatment LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN puppies AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN treatment_puppies AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T2.professional_id , T2.cell_number FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T2.professional_id , T2.cell_number FROM treatments AS T1 JOIN physicians AS T2 ON T1.professional_id = T2.professional_id GROUP BY T2.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T2.role_code = ' veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_birth , T3.first_name FROM pets AS T1 JOIN treatments AS T2 ON T1.treatment_id = T2.treatment_id JOIN professionals AS T3 ON T2.professional_id = T3.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T3.treatment_type_description FROM treatments AS T1 JOIN charge AS T2 ON T1.cost_of_treatment = T2.cost_of_treatment JOIN treatment_types AS T3 ON T1.treatment_type_code = T3.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM treatments AS T1 JOIN treatment_pores AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T4.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treats AS T3 ON T2.dog_id = T3.dog_id JOIN pets AS T4 ON T2.owner_id = T4.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T3.date_of_hospital FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code JOIN treatment_types AS T3 ON T1.dog_id = T3.dog_id WHERE T2.breed_name = (SELECT min(breed_name) FROM breeds) AND T3.role_code = 'healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT name , date_of_birth FROM dogs WHERE breed_code = (SELECT min(breed_code) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T1.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = 'Virginia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.name , T2.name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = 'Virginia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_of_arrived , T1.date_of_departed FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'animal'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_of_arrived , T1.date_of_leave FROM dogs AS T1 JOIN treatment_puppies AS T2 ON T1.dog_id = T2.dog_id WHERE T2.role_code = 'health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE role_code = 'veterinarian' AND state = 'Hawaii' OR state = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'male' AND age = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'male' AND age = 100", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM puppies AS T1 JOIN treats AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = 'petroleum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM puppies WHERE gender = 'male' AND first_name = 'protoporphyrinogen IX' AND last_name = 'petroleum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM ( SELECT * FROM T1 JOIN treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN treats AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T1.role_code = 'veterinarian' AND T3.treatment_type_code = 'health care' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM ( SELECT DISTINCT T2.professional_id FROM treats AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T1.dog_id = T3.dog_id WHERE T3.breed_name = \"Puppies\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE \"%West%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT T2.role_code , T2.street , T2.city , T2.state FROM owners AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T1.email_address FROM Guardians AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT T2.first_name , T2.last_name , T2.email_address FROM owners AS T1 JOIN guardians AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM puppies WHERE age < (SELECT avg(age) FROM puppies)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM puppies WHERE age < (SELECT avg(age) FROM puppies)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM treatments WHERE charge_type = 'healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM puppies WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM puppies AS T1 JOIN treatment_Types AS T2 ON T1.dog_id = T2.dog_id WHERE T2.role_code = 'petitor' OR T2.role_code = 'doctor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE id NOT IN ( SELECT owner_id FROM dogs );", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code = 'veterinarian' EXCEPT SELECT count(*) FROM ( SELECT T1.professional_id FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T2.breed_name = 'puppy' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = \"animalpet\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM puppies WHERE abandoned_yn = '1' AND gender = 'male' UNION SELECT name , age , weight FROM puppies WHERE abandoned_yn = '0' AND gender = 'female'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM puppies WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE gender = 'male' OR gender = 'female'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs WHERE gender = 'male' OR gender = 'female'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs ORDER BY date_of_birth DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs WHERE gender = 'male'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , sum(charge_amount) FROM charges GROUP BY charge_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , sum(charge_amount) FROM charges GROUP BY charge_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges WHERE charge_type = (SELECT charge_type FROM charges GROUP BY charge_type ORDER BY sum(charge_amount) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges GROUP BY charge_type ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM PROFESSIONALS WHERE role_code = \"VETERINARY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM PROFESSIONS WHERE role_code = ' veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT T1.breed_name , T2.size_description FROM Breeds AS T1 JOIN Sizes AS T2 ON T1.breed_code = T2.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM dogs AS T1 JOIN sizes AS T2 ON T1.size_code = T2.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T3.treatment_type_description FROM professionals AS T1 JOIN treatment_Types AS T2 ON T1.professional_id = T2.professional_id JOIN treatment_office AS T3 ON T2.treatment_office = T3.treatment_office WHERE T1.role_code = 'veterinarian' INTERSECT SELECT T4.first_name , T4.last_name , T3.treatment_type_description FROM treatment_office AS T3 JOIN treatment_Types AS T4 ON T2.treatment_office = T3.treatment_office WHERE T4.role_code = 'medical care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM veterinaries AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Country FROM singer WHERE Voice_Region = \"Vocal\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Country FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Country FROM singer GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Country FROM singer GROUP BY Country HAVING COUNT(*) = \"MSOT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(Net_Worth_Millions) , Country FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT max(Net_Worth_Millions) , Country FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Title , T3.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID JOIN artist AS T3 ON T1.Singer_ID = T3.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Title , T3.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID JOIN song AS T3 ON T1.Singer_ID = T3.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , sum(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT sum(T1.sales) , T2.name FROM song AS T1 JOIN singer AS T2 ON T1.song_id = T2.song_id GROUP BY T2.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Birth_Year FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Birth_Year FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT t1.feature_type_name FROM Ref_Feature_Types AS t1 JOIN Other_Available_Features AS t2 ON t1.feature_type_code = t2.feature_type_code WHERE t2.feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T1.property_type_description FROM Ref_Property_Types AS T1 JOIN Properties AS T2 ON T1.property_type_code = T2.property_type_code WHERE T2.property_type_code = \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'HSE' OR room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..c729fc84f27edef50858985177781df27b4f4992 --- /dev/null +++ b/infer/qwen/spider_syn/sft_sft_qwen3_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer WHERE Is_male = 'No';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT Name , Country , Age FROM singer WHERE Is_male = 'No' ORDER BY Age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT Name, Country, Age FROM singer ORDER BY Age DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(Age), min(Age), max(Age) FROM singer WHERE Country = \"France\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age), min(age), max(age) FROM singer WHERE country = \"France\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT Song_name , Song_release_year FROM singer WHERE Age = (SELECT min(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT Country FROM singer WHERE Age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer) AND Is_male = 'No';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT Position, Name FROM stadium WHERE Capacity BETWEEN 5000 AND 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT Location , Name FROM stadium WHERE Capacity BETWEEN 5000 AND 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Capacity) , max(Capacity) FROM stadium;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Capacity) , max(Capacity) FROM stadium;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.Stadium_ID = T2.Stadium_ID GROUP BY T1.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.Stadium_ID , COUNT(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.Stadium_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.capacity FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year > 2013 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Highest FROM stadium GROUP BY Highest ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT Name FROM stadium WHERE Stadium_ID NOT IN (SELECT Stadium_ID FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT Country FROM singer WHERE Age > 40 INTERSECT SELECT Country FROM singer WHERE Age < 30;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_Name , T1.theme , (SELECT count(*) FROM singer_in_concert AS T2 WHERE T2.concert_ID = T1.concert_ID ) FROM concert AS T1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.concert_Name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.concert_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.singer_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT DISTINCT T1.concert_Name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID JOIN singer AS T3 ON T2.singer_ID = T3.singer_ID WHERE T1.year = 2014;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT DISTINCT T1.name FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id WHERE T3.year = 2014;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT DISTINCT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT DISTINCT T1.name , T1.position FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T1.name , T1.address FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2014 INTERSECT SELECT T1.name , T1.address FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.year = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM stadium ORDER BY capacity DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert WHERE stadium_id = (SELECT stadium_id FROM stadium ORDER BY capacity DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM pets WHERE pet_type = 'puppy' AND pet_age = ( SELECT min(age) FROM student WHERE sex = 'F' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM pets WHERE pet_type = 'puppy' AND pet_age = (SELECT min(age) FROM student WHERE sex = 'F') LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT pet_type , max(weight) FROM pets GROUP BY pet_type;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT T1.pet_type , max(T1.weight) , T2.city_code FROM Pets AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.pet_type;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Age > 20);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Age > 20);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE Sex = \"F\") AND PetType = \" puppy \";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE sex = 'F');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pet_type) FROM pets;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT pet_type) FROM pets;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_age < 2 OR T3.pet_age > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = 'cat' OR T3.pet_type = 'dog'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"kitten\" INTERSECT SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'kitten' INTERSECT SELECT T1.fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = 'puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT Major , Age FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet WHERE PetID IN (SELECT PetID FROM Pets WHERE PetType = \"kitten\"));", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"dog\" EXCEPT SELECT T1.Fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"dog\" EXCEPT SELECT T1.Fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pet_type = \"kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT PetType , weight FROM pets ORDER BY pet_age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_age , weight FROM pets WHERE pet_age = ( SELECT min(pet_age) FROM pets )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT T1.pet_age , T1.weight FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.pet_id = T2.pet_id WHERE T2.pet_age > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT T1.pet_age , T1.weight FROM Has_Pet AS T1 JOIN Pets AS T2 ON T1.pet_age > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(pet_age) , max(pet_age) FROM pets GROUP BY pet_type;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(pet_age) , max(pet_age) FROM pets GROUP BY pet_type;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.Fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.Fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT PetID FROM Has_Pet WHERE StuID IN (SELECT StuID FROM Student WHERE LName = 'Smith');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT petid FROM has_pet WHERE StuID IN (SELECT StuID FROM Student WHERE lname = 'Smith');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.Fname , T1.Sex FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT fname , sex FROM student WHERE StuID IN (SELECT StuID FROM Has_Pet GROUP BY StuID HAVING count(*) > 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT Student.LName FROM Student JOIN Has_Pet ON Student.StuID = Has_Pet.StuID JOIN Pets ON Has_Pet.PetID = Pets.PetID WHERE Pets.pet_age = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT Student.LName FROM Student JOIN Has_Pet ON Student.StuID = Has_Pet.StuID JOIN Pets ON Has_Pet.PetID = Pets.PetID WHERE Pets.pet_age = 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(Age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM student WHERE stuID NOT IN (SELECT stuID FROM has_pet);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.Continent , T1.Continents , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.Contid = T2.Continent GROUP BY T1.Contid;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T1.ContId , T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id , count(model_list.modelid) FROM car_makers JOIN model_list ON car_makers.id = model_list.maker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id , count(model_list.Maker) FROM car_makers JOIN model_list ON car_makers.id = model_list.Maker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT MakeId , model FROM car_names JOIN cars_data ON car_names.makeid = cars_data.id ORDER BY Horsepower ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM model_list ORDER BY model ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT maker FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM car_names WHERE cars_data.weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT car_makers.FullName FROM car_makers JOIN cars_data ON car_makers.Id = cars_data.Id WHERE cars_data.Year = 1970;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Id WHERE T2.Year = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT T1.Make, T1.Yearly FROM car_names AS T1 JOIN cars_data AS T2 ON T1.MakeId = T2.Id JOIN model_list AS T3 ON T2.Maker = T3.Id WHERE T2.Year = (SELECT min(Yearly) FROM cars_data) GROUP BY T2.Maker;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT car_makers.Maker , cars_data.Year FROM car_makers JOIN cars_data ON car_makers.Id = cars_data.Id ORDER BY cars_data.Year ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT model FROM model_list WHERE maker NOT IN (SELECT maker FROM car_makers WHERE country NOT IN (SELECT countryid FROM countries WHERE continent = 'Americas')) INTERSECT SELECT model FROM car_names WHERE makeid NOT IN (SELECT makeid FROM cars_data WHERE YEAR > 1980)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.ModelId = T2.Id WHERE T2.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.ContId;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , COUNT(*) FROM continents AS T1 JOIN countries AS T2 ON T1.ContId = T2.Continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryName ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , car_makers.fullname FROM car_makers JOIN model_list ON car_makers.id = model_list.maker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , car_makers.id , car_makers.fullname FROM car_makers JOIN model_list ON car_makers.id = model_listmaker GROUP BY car_makers.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT Accelerate FROM cars_data WHERE Id = (SELECT MakeId FROM car_names WHERE Model = \"amc hornet sportabout (sw)\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT Accelerate FROM cars_data WHERE Id = (SELECT MakeId FROM car_names WHERE Model = \"amc hornet sportabout (sw)\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE Country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(DISTINCT car_makers.Id) FROM car_makers JOIN countries ON car_makers.Country = countries.CountryName WHERE countries.Continent = 'Europe';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(DISTINCT model) FROM model_list WHERE maker IN (SELECT id FROM car_makers WHERE country = \"USA\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers JOIN countries ON car_makers.Country = countries.CountryId WHERE countries.Continent = \"Americas\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND Year = 1974;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(Weight) FROM cars_data WHERE Cylinders = 8 AND YEar = 1974;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT FullName , Model FROM car_makers JOIN model_list ON car_makers.Id = model_list.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT FullName , Model FROM car_makers JOIN model_list ON car_makers.Id = model_list.Maker;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT DISTINCT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT DISTINCT T1.CountryName , T1.CountryId FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT Id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(Weight) FROM cars_data GROUP BY YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(Weight) , YEAR FROM cars_data GROUP BY YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T2.Country HAVING count(*) >= 3 INTERSECT SELECT countryname FROM countries WHERE continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T2.Country HAVING count(*) >= 3 INTERSECT SELECT CountryName FROM countries WHERE Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , car_makers.Maker FROM cars_data JOIN car_makers ON cars_data.Id = car_makers.Id WHERE cars_data.Cylinders = 3 GROUP BY car_makers.Maker;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(Horsepower) , car_makers maker FROM cars_data JOIN car_makers ON cars_data.Id = car_makers.Id WHERE cars_data.Cylinders = 3 GROUP BY car_makers;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Id IN (SELECT MakeId FROM car_names WHERE Model = \"volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE Id IN (SELECT MakeId FROM car_names INTERSECT SELECT MakeId FROM model_list WHERE Maker = \"Volvo\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT Accelerate , Cylinders FROM cars_data GROUP BY Cylinders ORDER BY Accelerate DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(accelerate) FROM cars_data;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT model FROM car_names GROUP BY model ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Maker , Model FROM model_list GROUP BY Maker , Model ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(DISTINCT model) FROM model_list WHERE maker = (SELECT id FROM car_makers WHERE fullname = \"American Motor Company\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM model_list WHERE Maker = (SELECT Id FROM car_makers WHERE FullName = 'American Motor Company')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT car_makers.fullname , car_makers.id FROM car_makers JOIN model_list ON car_makers.id = model_list.Maker GROUP BY car_makers.id HAVING count(*) > 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2maker JOIN cars_data AS T3 ON T3.id = T4makeid WHERE T1.fullname = \"General Motors\" OR T3.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.modelid = T2.id JOIN car_makers AS T3 ON T1maker = T3.id WHERE T3 maker = 'General Motors' OR T2.weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE Weight BETWEEN 3000 AND 4000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE Weight < 4000 INTERSECT SELECT YEAR FROM cars_data WHERE Weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT MPG FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT max(accelerate) FROM cars_data;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE MakeId = (SELECT MakeId FROM cars_data ORDER BY Accelerate LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE MakeId IN (SELECT MakeId FROM cars_data ORDER BY Accelerate LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT accelerate FROM cars_data ORDER BY power DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Accelerate > (SELECT max(Horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT COUNT(DISTINCT car_makers.Country) FROM car_makers WHERE car_makers.Country IN (SELECT country FROM car_makers GROUP BY country HAVING count(*) > 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM (SELECT * FROM car_makers GROUP BY Country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE Cylinders = 4 ORDER BY Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data WHERE Cylinders = 4 ORDER BY Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT car_names.MakeId , car_names.Make FROM car_names JOIN cars_data ON cars_data.Id = car_names.MakeId WHERE cars_data.Horsepower > (SELECT min(Horsepower) FROM cars_data) AND cars_data.Cylinders > 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Id WHERE T2.Cylinders < 4 AND T2.Horsepower < (SELECT min(Horsepower) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR Year < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE Cylinders = 8 OR Year < 1980;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT model FROM car_names WHERE makeid NOT IN (SELECT id FROM car_makers WHERE country = 'Ford Motor Company')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.ModelId = T2.Id WHERE T2.Weight < 3500 EXCEPT SELECT DISTINCT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.ModelId = T2.Id JOIN car_makers AS T3 ON T2.Id = T3.Id WHERE T3.Country = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT DISTINCT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT countryname FROM countries WHERE countryid NOT IN (SELECT country FROM car_makers)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT maker FROM car_makers WHERE id IN (SELECT maker FROM model_list GROUP BY maker HAVING count(*) >= 2 INTERSECT SELECT maker FROM car_makers GROUP BY maker HAVING count(*) >= 3)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.Id GROUP BY T1.Id HAVING count(*) > 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 3 UNION SELECT T1.CountryId , T1.CountryName FROM countries AS T1 JOIN car_names AS T2 ON T1.CountryId = T2.MakeId WHERE MakeId = (SELECT Id FROM car_makers WHERE FullName = 'Italy')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT countryid , countryname FROM countries WHERE countryid IN (SELECT country FROM car_makers GROUP BY country HAVING count(*) > 3 UNION SELECT country FROM car_makers WHERE fullname = 'Fiat') LIMIT 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Airline LIKE '%Airways%JetBlue Airways%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Country FROM airlines WHERE Abbreviation = 'JET' UNION SELECT Country FROM airlines WHERE Abbreviation = 'Jetblue'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = 'Jetblue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT Airline , Abbreviation FROM airlines WHERE Country = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airlines;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(FlightNo) FROM flights;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Abbreviation LIKE '%UAL%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT Airline FROM airlines WHERE Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines WHERE Country = 'USA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , CountryAbbrev FROM airports WHERE AirportName = \"Alton\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , CountryAbbrev FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode = 'AKO';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE AirportName LIKE '%ATO%') AND DestAirport IN (SELECT AirportCode FROM airports WHERE AirportName LIKE '%ATO%');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights WHERE DestAirport = \"ATL\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.SourceAirport = airports.AirportCode WHERE airports.City = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE City LIKE '%Aberdeen%');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights INNER JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.City = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.City = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports AS source ON flights.SourceAirport = source.AirportCode JOIN airports AS destination ON flights.DestAirport = destination.AirportCode WHERE source.City = 'Aberdeen' AND destination.City = 'Ashley';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights WHERE sourceairport = (SELECT airportcode FROM airports WHERE city = 'Aberdeen') AND destairport = (SELECT airportcode FROM airports WHERE city = 'Ashley');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'JetBlue Airways';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'Jetblue Airways';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'United Airlines' AND DestAirport = 'ASY';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.AirportName = 'ASY' AND flights.Airline = 'United Airlines';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'United Airlines' AND SourceAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights WHERE Airline = 'United' AND SourceAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights INNER JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.CountryAbbrev = 'USA' AND airports.City = 'Aberdeen';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.AirportName = 'Aberdeen' AND flights.Airline = 'United';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.City FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT SourceAirport , COUNT(*) FROM flights GROUP BY SourceAirport ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT SourceAirport FROM flights GROUP BY SourceAirport ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT DestAirport , COUNT(*) FROM flights GROUP BY DestAirport ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT DestAirport , COUNT(*) FROM flights GROUP BY DestAirport ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.Abbreviation , T1.CountryAbbrev FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.Airline GROUP BY T1.uid ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T1.AirportName , T1.CountryAbbrev FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T2.SourceAirport ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT DestAirport FROM flights WHERE SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT DestAirport FROM flights WHERE SourceAirport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT DestAirport FROM flights WHERE DestAirport = 'AHD';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT DISTINCT DestAirport FROM flights WHERE DestAirport IN (SELECT AirportCode FROM airports WHERE AirportName = \"Helsinki Vantaa International Airport\") UNION SELECT DISTINCT SourceAirport FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE AirportName = \"Helsinki Vantaa International Airport\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT DISTINCT Airways FROM flights WHERE SourceAirport = 'APG' AND DestAirport = 'CVO' UNION SELECT DISTINCT Airways FROM flights WHERE SourceAirport = 'CVO' AND DestAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.Airway FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportCode = 'APG' INTERSECT SELECT T1.Airway FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportCode = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DISTINCT Airways FROM flights WHERE SourceAirport = \"CVO\" EXCEPT SELECT DISTINCT Airways FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT DestAirport FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE AirportName = \"CVO\") EXCEPT SELECT DestAirport FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE AirportName = \"APG\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT AirportCode FROM flights GROUP BY AirportCode HAVING COUNT(*) >= 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline HAVING COUNT(*) >= 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT AirportCode FROM flights GROUP BY AirportCode HAVING count(*) < 200;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT Airline FROM flights GROUP BY Airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE Airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = 'APG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = \"APG\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT DISTINCT FlightNo FROM flights WHERE SourceAirport IN (SELECT AirportCode FROM airports WHERE City = \"Aberdeen \")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"ABZ\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE DestAirport IN (SELECT AirportCode FROM airports WHERE City = \"Aberdeen\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT DestAirport FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.AirportName = \"Aberdeen\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT DISTINCT FlightNo FROM flights WHERE DestAirport IN (SELECT AirportCode FROM airports WHERE City = 'Aberdeen') OR DestAirport IN (SELECT AirportCode FROM airports WHERE City = 'Abilene')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights JOIN airports ON flights.DestAirport = airports.AirportCode WHERE airports.City = 'Aberdeen' OR airports.City = 'Abilene';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportName FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights UNION SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT AirportCode FROM airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM flights UNION SELECT DestAirport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT Name FROM employee ORDER BY Age ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT City, COUNT(*) FROM employee GROUP BY City;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT City, COUNT(*) FROM employee GROUP BY City;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT City, COUNT(*) FROM employee GROUP BY City;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT City, COUNT(*) FROM employee GROUP BY City;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT Manager_name , District FROM shop ORDER BY Number_products DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT Name , District FROM shop ORDER BY Number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(Number_products) , max(Number_products) FROM shop;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(Number_products) , max(Number_products) FROM shop;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT Name , District FROM shop ORDER BY Number_products DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , city , district FROM shop ORDER BY number_products DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT employee.Name FROM employee JOIN evaluation ON evaluation.Employee_ID = employee.Employee_ID GROUP BY employee.Name ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT employee.Name FROM employee JOIN evaluation ON employee.Employee_ID = evaluation.Employee_ID ORDER BY evaluation.Bonus DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT employee.Name FROM employee JOIN evaluation ON evaluation.Employee_ID = employee.Employee_ID ORDER BY evaluation.Bonus DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop WHERE shop_id IN (SELECT shop_id FROM hiring GROUP BY shop_id ORDER BY count(*) DESC LIMIT 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM shop AS T1 JOIN hiring AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T1.name , count(*) FROM shop AS T1 JOIN hiring AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T1.name , count(*) FROM shop AS T1 JOIN hiring AS T2 ON T1.shop_id = T2.shop_id JOIN employee AS T3 ON T2.employee_id = T3.employee_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(Bonus) FROM evaluation;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(Bonus) FROM evaluation;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT District FROM shop WHERE Number_products < 3000 INTERSECT SELECT District FROM shop WHERE Number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT District FROM shop WHERE Number_products < 3000 INTERSECT SELECT District FROM shop WHERE Number_products > 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee UNION SELECT count(DISTINCT district) FROM shop;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id, document_name, document_description FROM documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT document_id, document_name, document_description FROM documents;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT Document_Name , Template_ID FROM Documents WHERE Document_Description LIKE \"%w%\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_name , T1.document_id FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T2.paragraph_text LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT T1.document_id , T1.template_id , T1.document_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"Layout\" UNION SELECT T1.document_id , T1.template_id , T1.document_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"Paper\" UNION SELECT T1.document_id , T1.template_id , T1.document_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"Ref\" UNION SELECT T1.document_id , T1.template_id , T1.document_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"Other\" UNION SELECT T1.document_id , T1.template_id , T1.document_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"Index\" UNION SELECT T1.document_id , T1.template_id , T1.document_description FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"Paper\" AND T1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT T1.document_id , T1.template_id , T1.document_name FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT template_type_code) FROM templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT Template_Type_Code) FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Templates WHERE Template_Type_Code = 'PPT'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents WHERE Template_ID IN (SELECT Template_ID FROM Templates WHERE Template_Type_Code = 'PPT');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT T1.Template_ID , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.Template_ID = T2.Template_ID GROUP BY T1.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT Template_ID , COUNT(*) FROM Templates GROUP BY Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.template_type_code , T1.template_id FROM templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code JOIN documents AS T3 ON T1.template_id = T3.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Template_Type_Code , T1.Template_ID FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Documents AS T3 ON T1.Template_ID = T3.Template_ID GROUP BY T1.Template_ID ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING COUNT(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT Template_ID FROM Documents GROUP BY Template_ID HAVING COUNT(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM templates WHERE template_id NOT IN (SELECT template_id FROM documents)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT Template_ID FROM Templates WHERE Template_Type_Code = \"Layout\" EXCEPT SELECT Template_ID FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM Templates;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.Template_ID , T1.Version_Number , T1.Template_Type_Code FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT Templates.Template_ID , Templates.Version_Number , Ref_Template_Types.Template_Type_Description FROM Templates JOIN Ref_Template_Types ON Templates.Template_Type_Code = Ref_Template_Types.Template_Type_Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT Template_Type_Description FROM Ref_Template_Types;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Template_ID FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT Template_ID FROM Templates WHERE Template_Type_Code = \"PP\" OR Template_Type_Code = \"PPT\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Templates WHERE Template_Type_Code = \"CV\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Templates WHERE Template_Type_Code = \"CV\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Version_Number , Template_Details FROM Templates WHERE Version_Number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT Template_ID , Template_Type_Code FROM Templates WHERE Version_Number > 5;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Template_Type_Code, COUNT(*) FROM Templates GROUP BY Template_Type_Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT Template_Type_Code, COUNT(*) FROM Templates GROUP BY Template_Type_Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Template_Type_Code FROM Templates GROUP BY Template_Type_Code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code IN (SELECT Template_Type_Code FROM Templates GROUP BY Template_Type_Code ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Template_Type_Code FROM Templates GROUP BY Template_Type_Code HAVING COUNT(*) < 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code IN (SELECT Template_Type_Code FROM Templates GROUP BY Template_Type_Code HAVING COUNT(*) < 3);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT Version_Number , Template_Type_Code FROM Templates ORDER BY Version_Number ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT Version_Number , Template_Type_Code FROM Templates ORDER BY Version_Number ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = \"Data base\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T1.Document_Name = \"Data base\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM Documents WHERE template_id IN (SELECT template_id FROM Templates WHERE template_type_code = \"BK\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT document_name FROM documents WHERE template_id IN (SELECT template_id FROM templates WHERE template_type_code = \"BK\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT Ref_Template_Types.Template_Type_Description , COUNT(Templates.Template_ID) FROM Ref_Template_Types JOIN Templates ON Templates.Template_Type_Code = Ref_Template_Types.Template_Type_Code GROUP BY Templates.Template_Type_Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T2.Template_Type_Description , count(*) FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code GROUP BY T1.Template_Type_Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Template_Type_Code FROM Templates GROUP BY Template_Type_Code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Template_Type_Code FROM Templates GROUP BY Template_Type_Code ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Code NOT IN (SELECT Template_Type_Code FROM Templates)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code NOT IN (SELECT Template_Type_Code FROM Templates WHERE Template_Type_Code IN (SELECT Template_Type_Code FROM Templates INTERSECT SELECT Template_Type_Code FROM Documents))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Description , Template_Details FROM Ref_Template_Types JOIN Templates ON Ref_Template_Types.Template_Type_Code = Templates.Template_Type_Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT Template_Type_Code , Template_Type_Description FROM Ref_Template_Types;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = \"AD\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Description = \"Book\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = \"Book\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT T2.Template_Type_Description FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.Template_Type_Code = T2.Template_Type_Code JOIN Documents AS T3 ON T1.Template_ID = T3.Template_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT Other_Details FROM Documents WHERE Template_ID IN (SELECT Template_ID FROM Templates WHERE Template_Type_Code IN (SELECT Template_Type_Code FROM Ref_Template_Types)) INTERSECT SELECT Other_Details FROM Paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Template_ID FROM Templates WHERE Template_Type_Code = (SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = \"Presentation\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT Template_ID FROM Templates WHERE Template_Type_Code = (SELECT Template_Type_Code FROM Ref_Template_Types WHERE Template_Type_Description = 'Presentation');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM Paragraphs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM paragraphs WHERE document_id = (SELECT document_id FROM documents WHERE document_name = 'Summer Show');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM paragraphs WHERE document_id IN (SELECT document_id FROM documents WHERE document_name = 'Summer Show');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE Paragraph_Text = 'Korea';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT Other_Details FROM Paragraphs WHERE Paragraph_Text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT Paragraph_ID , Paragraph_Text FROM Paragraphs WHERE Document_ID IN (SELECT document_id FROM Documents WHERE document_name = 'Welcome to NY');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT Paragraphs.Paragraph_ID , Paragraphs.Paragraph_Text FROM Paragraphs JOIN Documents ON Paragraphs.Document_ID = Documents.Document_ID WHERE Documents.Document_Name = \"Welcome to NY\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT Paragraph_Text FROM Paragraphs WHERE Document_ID = (SELECT document_id FROM Documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT Paragraph_Text FROM Paragraphs WHERE Document_ID = (SELECT document_id FROM Documents WHERE document_name = 'Customer reviews');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id, count(*) FROM paragraphs GROUP BY document_id ORDER BY document_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT DISTINCT document_id , count(*) FROM paragraphs GROUP BY document_id ORDER BY document_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT document_id , document_name , count(*) FROM documents JOIN paragraphs ON documents.document_id = paragraphs.document_id GROUP BY document_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT T1.document_id , T1.template_id , T1.document_name , count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Documents.document_id , Documents.document_name FROM Documents JOIN Paragraphs ON Documents.document_id = Paragraphs.document_id GROUP BY Documents.document_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.document_id , T1.document_name FROM documents AS T1 JOIN paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT Paragraph_ID FROM Paragraphs WHERE Paragraph_Text = 'Brazil' OR Paragraph_Text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT teacher.name , course_arrange.course_id FROM teacher JOIN course_arrange ON teacher.teacher_id = course_arrange.teacher_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT teacher.name , course.curriculum FROM teacher JOIN course_arrange ON teacher.teacher_id = course_arrange.teacher_id JOIN course ON course_arrange.course_id = course.course_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T1.Name , T1.Course FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID JOIN course AS T3 ON T2.Course_ID = T3.Course_ID ORDER BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T1.Name , T1.Course FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T1.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID 2.Name WHERE T1.Course_ID 2.Course_ID 2.Course 2.\"math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT teacher.name FROM teacher JOIN course_arrange ON teacher.teacher_id = course_arrange.teacher_id JOIN course ON course_arrange.course_id = course.course_id WHERE course.course = 'math';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T.Name , COUNT(*) FROM teacher AS T JOIN course_arrange AS TA ON T.Teacher_ID = TA.Teacher_ID GROUP BY T.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT teacher.name FROM teacher JOIN course_arrange ON teacher.teacher_id = course_arrange.teacher_id GROUP BY teacher.teacher_id HAVING count(DISTINCT course_id) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T1.Name FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(DISTINCT T2.Course_ID) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT name FROM teacher WHERE teacher_id NOT IN (SELECT teacher_id FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE Age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(Age) FROM visitor WHERE Level_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , level_of_membership FROM visitor WHERE level_of_membership > 4 ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT Museum_ID , Name FROM museum ORDER BY Num_of_Staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT Open_Year , Num_of_Staff FROM museum WHERE Name = 'Plaza Museum'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year < 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T1.id , T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name , T1.Level_of_membership FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T1.id ORDER BY sum(T2.Total_spent) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Museum_ID , T1.Name FROM museum AS T1 JOIN visit AS T2 ON T1.Museum_ID = T2.Museum_ID GROUP BY T1.Museum_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.age FROM visitor AS T1 JOIN visit AS T2 ON T1.id = T2.visitor_id GROUP BY T2.visitor_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(Num_of_Ticket) , max(Num_of_Ticket) FROM visit;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(Total_spent) FROM visit WHERE visitor_ID IN (SELECT ID FROM visitor WHERE Level_of_membership = 1);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_id = T3.museum_id WHERE T3.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE ID NOT IN (SELECT visitor_ID FROM visit WHERE museum_ID IN (SELECT museum_ID FROM museum WHERE open_year > 2010));", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year < 2008 OR open_year > 2013;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(DISTINCT player_id) FROM rankings;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM players;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(winner_age) , avg(loser_age) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT max(loser_rank) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT COUNT(DISTINCT loser_name) FROM matches;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING COUNT(*) > 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT YEAR FROM matches WHERE YEAR = 2013 OR YEAR = 2016 GROUP BY YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_id FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY max(T1.winner_age) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T1.player_id GROUP BY T1.player_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T2.player_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.winner_name ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.winner_name ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id ¼ T2.winner_id WHERE T2.tourney_name ¼ 'Australian Open' AND T2.winner_rank_points ¼ (SELECT max(winner_rank_points) FROM matches WHERE tourney_name ¼ 'Australian Open') LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.winner_id = T3.player_id WHERE T3.ranking_points = ( SELECT max(ranking_points) FROM rankings ) AND T1.tourney_name = 'Australian Open' GROUP BY T1.winner_id ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT winner_name , loser_name FROM matches ORDER BY tourney_date LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(ranking_points) , players.first_name , players.last_name FROM rankings JOIN players ON rankings.player_id = players.player_id GROUP BY players.player_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT first_name , avg(ranking_points) FROM players JOIN rankings ON players.player_id = rankings.player_id GROUP BY players.player_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT sum(loser_rank_points) , first_name FROM matches JOIN players ON matches.loser_id = players.player_id GROUP BY matches.loser_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T1.first_name , sum(T1.loser_rank_points) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , COUNT(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , COUNT(*) FROM players GROUP BY country_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT DISTINCT country_code FROM players GROUP BY country_code HAVING COUNT(*) > 50;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING COUNT(*) > 50;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT count(*) , ranking_date FROM rankings GROUP BY ranking_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT count(*) , ranking FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , COUNT(*) FROM matches GROUP BY YEAR;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , COUNT(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT winner_id) FROM matches WHERE winner_id IN (SELECT player_id FROM players WHERE hand = 'left') AND YEAR(tourney_date) = 1994;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM (SELECT DISTINCT winner_id FROM matches WHERE winner_hand = \"left\" INTERSECT SELECT player_id FROM rankings WHERE ranking_date = (SELECT max(ranking_date) FROM rankings))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points , T1.winner_seed FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN rankings AS T3 ON T1.winner_id = T3.player_id GROUP BY T1.winner_id ORDER BY T3.ranking_points DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id JOIN rankings AS T3 ON T2.winner_id = T3.player_id GROUP BY T3.player_id ORDER BY sum(T3.ranking_points) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , COUNT(*) FROM players GROUP BY hand;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , COUNT(*) FROM players GROUP BY hand;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT caused_by_ship_id , max(killed) , min(killed) FROM death GROUP BY caused_by_ship_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT killed , injured FROM death WHERE caused_by_ship_id IN (SELECT id FROM ship WHERE tonnage = 't');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT caused_by_ship_id , id FROM death GROUP BY caused_by_ship_id HAVING sum(killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT ship.id , ship.name FROM ship JOIN death ON ship.id = death.caused_by_ship_id GROUP BY ship.id ORDER BY sum(injured) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT COUNT(DISTINCT result) FROM battle;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE id NOT IN (SELECT lost_in_battle FROM ship WHERE tonnage = 225);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T1.date , T1.id FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.date , T1.id FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , RESULT , bulgarian_commander FROM battle WHERE id NOT IN (SELECT lost_in_battle FROM ship WHERE location = 'English Channel') AND id NOT IN (SELECT lost_in_battle FROM ship WHERE disposition_of_ship = 'Lost')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1, line_2 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Degree_Programs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Degree_Programs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = 'math';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name LIKE '%math%';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM Addresses WHERE city = \"Port Chelsea\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.department_id FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_id , T1.department_name FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_name) FROM degree_programs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM Degree_Programs WHERE department_name = 'engineering';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM Degree_Programs WHERE department_id = (SELECT department_id FROM Departments WHERE department_name = 'engineering');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT course_id , course_name FROM Courses GROUP BY course_id HAVING COUNT(*) <= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) < 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id WHERE T2.degree_program_id = (SELECT degree_program_id FROM Degree_Programs WHERE department_id = (SELECT department_id FROM Departments WHERE department_name = 'Undergraduate')) GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.semester_id , T1.semester_name , T2.degree_program_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT department_description , other_details FROM Departments WHERE department_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT * FROM Departments WHERE department_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING COUNT(DISTINCT T2.degree_program_id) = 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , T2.degree_program_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING COUNT(DISTINCT T2.degree_program_id) = 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = \"Bachelors\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , COUNT(*) , T2.undergraduate_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , T2.student_enrolment_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN (SELECT semester_id FROM Student_Enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T1.semester_name FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T2.semester_id HAVING count(*) = 0;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id JOIN Student_Enrolment AS T3 ON T2.student_enrolment_id = T3.student_enrolment_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.department_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.department_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'North Carolina' EXCEPT SELECT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT last_name FROM Students WHERE permanent_address_id IN (SELECT address_id FROM Addresses WHERE state_province_county = \"North Carolina\") AND student_id NOT IN (SELECT student_id FROM Student_Enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.student_id , T1.date_first_registered FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_enrolment_id GROUP BY T1.student_id HAVING COUNT(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.student_id , T1.date_first_registered FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING COUNT(DISTINCT T2.course_id) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM Students WHERE permanent_address_id != current_address_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM Students WHERE permanent_address_id != current_address_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 , T1.city , T1.zip_postcode , T1.state_province_county , T1.country FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM Transcripts;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , other_student_details FROM Students ORDER BY date_first_registered ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM Students WHERE date_left IS NOT NULL;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT date_left FROM Students ORDER BY date_left DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_first_registered) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT other_details , student_course_id FROM Student_Enrolment_Courses GROUP BY student_course_id ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT course_id , student_enrolment_id FROM Student_Enrolment_Courses GROUP BY course_id , student_enrolment_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.date_first_registered FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.date_first_registered FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Courses AS T3 ON T2.course_id = T3.course_id JOIN Degree_Programs AS T4 ON T1.degree_program_id = T4.degree_program_id WHERE T4.degree_summary_name = 'Bachelor' INTERSECT SELECT T1.semester_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Courses AS T3 ON T2.course_id = T3.course_id JOIN Degree_Programs AS T4 ON T1.degree_program_id = T4.degree_program_id WHERE T4.degree_summary_name = 'Master'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Degree_Programs AS T3 ON T1.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Masters' INTERSECT SELECT T1.semester_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id JOIN Degree_Programs AS T3 ON T1.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT current_address_id) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T1.city FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.permanent_address_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT first_name, middle_name, last_name FROM Students ORDER BY first_name DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM Students ORDER BY last_name DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT other_details FROM Sections WHERE section_id = 'h';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM Sections WHERE section_name = 'h';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name , last_name FROM Students WHERE permanent_address_id -> Addresses.address_id AND country = 'Haiti' OR cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT first_name FROM Students WHERE permanent_address_id IN (SELECT address_id FROM Addresses WHERE country = 'Haiti') OR cell_mobile_number = '09700166582'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM Cartoon ORDER BY Title;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT Title FROM Cartoon ORDER BY Title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT * FROM Cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT Title , Directed_by FROM Cartoon ORDER BY Original_air_date;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM TV_Channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM TV_Channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT Content) FROM TV_Channel;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT id) FROM TV_Channel;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_Channel WHERE Language = \"English\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_Channel WHERE Language = \"English\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_Channel WHERE id IN (SELECT Channel FROM TV_series GROUP BY Channel) UNION SELECT Language , COUNT(*) FROM TV_Channel WHERE id IN (SELECT Channel FROM Cartoon GROUP BY Channel)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_Channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_Channel GROUP BY Language;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_Channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT TV_Channel.series_name FROM TV_Channel JOIN Cartoon ON TV_Channel.id = Cartoon.Channel WHERE Cartoon.Title = \"The Rise of the Blue Beetle!\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT TV_Channel.series_name FROM TV_Channel JOIN Cartoon ON TV_Channel.id = Cartoon.Channel WHERE Cartoon.Title = \"The Rise of the Blue Beetle\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Cartoon.Title FROM Cartoon JOIN TV_Channel ON Cartoon.Channel = TV_Channel.id WHERE TV_Channel.series_name = \"Sky Radio\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Title FROM Cartoon WHERE Channel = (SELECT id FROM TV_Channel WHERE series_name = \"Sky Radio\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT * FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Original_air_date FROM Cartoon WHERE Title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series JOIN Cartoon ON TV_series.Channel = Cartoon.Channel WHERE Cartoon.Title = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT TV_Channel.series_name FROM TV_Channel JOIN TV_series ON TV_series.Channel = TV_Channel.id WHERE TV_series.Episode = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT id FROM TV_Channel WHERE series_name = \"Sky Radio\" INTERSECT SELECT id FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT Episode FROM TV_series WHERE Channel IN (SELECT id FROM TV_Channel WHERE series_name = \"Sky Radio\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT Directed_by , COUNT(*) FROM Cartoon GROUP BY Directed_by;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT Directed_by , COUNT(*) FROM Cartoon GROUP BY Directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_Channel WHERE Hight_definition_TV = 'Yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_Channel WHERE Hight_definition_TV = 'Yes';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT country FROM tv_channel WHERE id IN (SELECT DISTINCT channel FROM cartoon WHERE written_by = 'Todd Casey');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT DISTINCT TV_Channel.Country FROM TV_Channel JOIN Cartoon ON Cartoon.Channel = TV_Channel.id WHERE Written_by = \"Todd Casey\" AND Content = \"TV\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT Country FROM TV_Channel WHERE id NOT IN (SELECT Channel FROM Cartoon WHERE Written_by = \"Todd Casey\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT distinct(TV_Channel.Country) FROM TV_Channel WHERE TV_Channel.id NOT IN (SELECT Cartoon.Channel FROM Cartoon WHERE Cartoon.Written_by = 'Todd Casey')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.Country FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel JOIN Cartoon AS T3 ON T1.id = T3.Channel WHERE T3.Direct_by = \"Ben Jones\" AND T3.Direct_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T1.series_name , T1.Language FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Content = \"Animation\" INTERSECT SELECT T1.series_name , T1.Language FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = \"Ben Jones\" INTERSECT SELECT T1.series_name , T1.Language FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_Channel WHERE Country = (SELECT Country FROM TV_Channel GROUP BY Country HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM TV_Channel WHERE id IN (SELECT Channel FROM TV_series GROUP BY Channel HAVING COUNT(*) > 2 UNION SELECT id FROM Cartoon WHERE id IN (SELECT Channel FROM Cartoon GROUP BY Channel HAVING COUNT(*) > 2))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_Channel WHERE id NOT IN (SELECT DISTINCT Channel FROM Cartoon WHERE Directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM TV_Channel WHERE id NOT IN (SELECT channel FROM Cartoon WHERE directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM Cartoon WHERE Directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM Cartoon WHERE Directed_by = \"Ben Jones\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM people WHERE Nationality = \"car gamer\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM poker_player WHERE people_id IN (SELECT people_id FROM people WHERE nationality = \"car\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Money_Rank) FROM poker_player;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM people WHERE Nationality = \"car\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(final_table_made) FROM poker_player WHERE earnings < 200000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(final_table_made) FROM poker_player WHERE Earnings < 200000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT name FROM people WHERE people_ID IN (SELECT people_ID FROM poker_player)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT people.Name FROM people JOIN poker_player ON poker_player.People_ID = people.People_ID WHERE poker_player.Final_Table_Made = 'Car';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT people.Name FROM people JOIN poker_player ON people.People_ID = poker_player.People_ID WHERE poker_player.Earnings > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name , T1.Final_Table_Made FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE people.People_ID IN (SELECT People_ID FROM people WHERE Height > 200);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(Money_Rank) FROM poker_player WHERE people.People_ID -> people.People_ID -> people.Height > 200;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T1.Nationality FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID GROUP BY T1.People_ID HAVING COUNT(DISTINCT T1.Nationality) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(DISTINCT People_ID) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number, contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT state , created FROM votes", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T1.contestant_number, T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING COUNT(DISTINCT T2.phone_number) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.contestant_number, T1.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T2.contestant_number ORDER BY count(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT area_code FROM AREA_CODE_STATE JOIN VOTES ON AREA_CODE_STATE.state = VOTES.state GROUP BY area_code ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT created , state , phone_number FROM VOTES JOIN CONTESTANTS ON VOTES.contestant_number = CONTESTANTS.contestant_number WHERE CONTESTANTS.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state JOIN contestants AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state JOIN contestants AS T3 ON T2.contestant_number = T3.contestant_number WHERE T3.contestant_name = 'Kelly Clauss'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT Name FROM country WHERE IndepYear > 1950;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT Name) FROM country WHERE GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT Name) FROM country WHERE GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Caribbean';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Oceania';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE Code = 'ANG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT Continent FROM country WHERE Code = 'AIA';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT district FROM city WHERE name = 'Kabul';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT region FROM country WHERE countrycode = \"AF\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT language FROM countrylanguage WHERE CountryCode = 'ABW' ORDER BY percentage DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage WHERE CountryCode = 'ABW' ORDER BY Percentage DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = 'Brazil';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = 'Brazil';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT Region , Population FROM country WHERE Name = 'Angola';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT Region , Population FROM country WHERE Name = 'Angola';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = 'Central Africa';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT LifeExpectancy FROM country WHERE Continent = 'Africa' AND Region = 'Central';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Asia' ORDER BY LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Asia' ORDER BY LifeExpectancy ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(population) , max(GNP) FROM country WHERE continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT count(*) , max(GNP) FROM country WHERE Continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = 'Africa' AND GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = 'Africa' AND GovernmentForm = 'Republic';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = 'Asia' OR Continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(population) FROM city WHERE district = 'Gelderland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(GNP), sum(Population) FROM country WHERE GovernmentForm = 'US territory';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(GNP) , count(*) FROM country WHERE Name = 'United States';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT Language) FROM countrylanguage;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT CountryCode) FROM countrylanguage;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT Language) FROM countrylanguage WHERE CountryCode = 'ABW';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(DISTINCT Language) FROM countrylanguage WHERE CountryCode = 'ABW';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE CountryCode = 'AFG' AND IsOfficial = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE CountryCode = 'AFG';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Code ORDER BY COUNT(DISTINCT T2.Language) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT country.name FROM country JOIN countrylanguage ON country.code = countrylanguage.countrycode GROUP BY country.code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(DISTINCT T2.Language) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(DISTINCT T2.Language) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(DISTINCT country.Code) FROM countrylanguage WHERE Language = 'English' INTERSECT SELECT countryCode FROM countrylanguage WHERE Language = 'Dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(DISTINCT Code) FROM countrylanguage WHERE Language = 'English' OR Language = 'Dutch' AND IsOfficial = '1';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT country.name FROM country WHERE country.code IN (SELECT countrycode FROM countrylanguage WHERE language = 'English' INTERSECT SELECT countrycode FROM countrylanguage WHERE language = 'French') GROUP BY country.code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT name FROM country WHERE code IN (SELECT countrycode FROM countrylanguage WHERE language = 'english' INTERSECT SELECT countrycode FROM countrylanguage WHERE language = 'french') GROUP BY code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM country WHERE code IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 1 GROUP BY countrycode HAVING count(DISTINCT language) = 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT name FROM country WHERE code IN (SELECT countrycode FROM countrylanguage WHERE isofficial = 1 GROUP BY countrycode HAVING language = 'english' OR language = ' french');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT continent) FROM countrylanguage WHERE language = 'Chinese' GROUP BY countrylanguage.countrycode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT COUNT(DISTINCT continent) FROM country WHERE code IN (SELECT countrycode FROM countrylanguage WHERE language = 'Chinese');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT region FROM countrylanguage WHERE language = 'English' OR language = 'Dutch'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT DISTINCT region FROM countrylanguage WHERE language = 'Dutch' OR language = 'English';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT Name FROM country WHERE Code IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'English') OR Code IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'Dutch');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT Name FROM country WHERE Code IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'English' UNION SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'Dutch');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT countrylanguage.Language FROM countrylanguage JOIN country ON countrylanguage.CountryCode = country.Code WHERE country.Continent = 'Asia' GROUP BY countrylanguage.Language ORDER BY sum(countrylanguage.Percentage) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT countrylanguage.Language FROM countrylanguage WHERE countrylanguage.CountryCode IN (SELECT Code FROM country WHERE Continent = 'Asia') GROUP BY countrylanguage.Language ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.GovernmentForm = 'Republic' INTERSECT SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.GovernmentForm = 'Republic' GROUP BY T1.Language HAVING COUNT(DISTINCT T1.CountryCode) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.GovernmentForm = 'Republic' INTERSECT SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode HAVING COUNT(DISTINCT T1.Language) = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT district FROM city JOIN countrylanguage ON city.countrycode = countrylanguage.countrycode WHERE language = 'English' GROUP BY district ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT max(T1.population) FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT Name , LifeExpectancy FROM country WHERE Continent = 'Asia' ORDER BY SurfaceArea DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT Name , SurfaceArea , LifeExpectancy FROM country WHERE Continent = 'Asia' ORDER BY SurfaceArea DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'English') GROUP BY Code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 1 AND Language = 'English');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') UNION SELECT sum(population) FROM country WHERE Code IN (SELECT Code FROM countrylanguage WHERE Language = 'English')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT count(*) FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'english');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT IsOfficial FROM countrylanguage WHERE CountryCode = (SELECT Code FROM country WHERE HeadOfState = 'Beatrix');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT IsOfficial FROM countrylanguage JOIN country ON countrylanguage.CountryCode = country.Code WHERE HeadOfState = 'Beatrix';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT IsOfficial) FROM countrylanguage WHERE Code IN (SELECT Code FROM country WHERE IndepYear < 1930);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(DISTINCT IsOfficial) FROM countrylanguage WHERE Code IN (SELECT Code FROM country WHERE IndepYear < 1930);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT max(SurfaceArea) FROM country WHERE Continent = 'Europe')}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT max(SurfaceArea) FROM country WHERE Continent = 'Europe') AND Continent != 'Europe';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "{\n \"sql\": \"SELECT Name FROM country WHERE Continent = 'Africa' AND Population < (SELECT min(population) FROM country WHERE continent = 'Asia')\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE population < (SELECT min(population) FROM country WHERE continent = 'Asia') AND continent = 'Africa';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT Name FROM country WHERE Population > (SELECT max(population) FROM country WHERE continent = 'Asia') AND continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "{\n \"sql\": \"SELECT Name FROM country WHERE Continent = 'Asia' AND Population > (SELECT max(population) FROM country WHERE continent = 'Africa')\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code2 FROM country WHERE Code2 NOT IN (SELECT Code2 FROM countrylanguage WHERE Language = 'English') UNION SELECT Code2 FROM country WHERE IsOfficial = 'Yes' AND Language = 'English' GROUP BY Code2 HAVING count(*) = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code2 FROM country WHERE Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English') GROUP BY Code2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT Code2 FROM country WHERE Code2 NOT IN (SELECT Code2 FROM countrylanguage WHERE Language = 'English') UNION SELECT Code2 FROM countrylanguage WHERE Language != 'English' GROUP BY Code2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT Code2 FROM country WHERE Code2 NOT IN (SELECT Code2 FROM countrylanguage WHERE Language = 'English') UNION SELECT Code2 FROM country WHERE Code2 = 'United Kingdom'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code2 FROM country WHERE GovernmentForm != 'Republic' AND Code NOT IN (SELECT Code FROM countrylanguage WHERE Language = 'English' AND IsOfficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT Code2 FROM country WHERE GovernmentForm != 'Republic' AND Code2 NOT IN (SELECT Code2 FROM countrylanguage WHERE IsOfficial = 'yes' AND Language != 'English')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT DISTINCT city.name FROM city JOIN country ON city.countrycode = country.code WHERE country.continent = 'Europe' AND countrylanguage.isofficial = 'No' AND countrylanguage.countrycode = city.countrycode AND countrylanguage.language = 'English';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Europe' EXCEPT SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = '1' AND T3.Language = 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.Language = \"Chinese\" AND T3.IsOfficial = \"yes\" AND T2.Continent = \"Asia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = 'Asia' AND CountryCode IN (SELECT Code FROM countrylanguage WHERE IsOfficial = 'yes' AND Language = 'Chinese') GROUP BY T1.Name;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT Name , IndepYear , SurfaceArea FROM country ORDER BY Population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name, IndepYear, population FROM country ORDER BY population LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT SurfaceArea , Name , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Code HAVING COUNT(*) >= 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT country.Code , country.Name , count(DISTINCT countrylanguage.Language) FROM country JOIN countrylanguage ON country.Code = countrylanguage.CountryCode GROUP BY country.Code HAVING count(DISTINCT countrylanguage.Language) > 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district, count(*) FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district, count(*) FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT GovernmentForm , sum(population) FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT GovernmentForm , sum(population) FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT Continent , avg(LifeExpectancy) , count(*) FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT continent , sum(population) , avg(LifeExpectancy) FROM country GROUP BY continent HAVING avg(LifeExpectancy) < 72;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Europe' AND Population = 80000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT Name FROM country WHERE Continent = 'Europe' AND Population = 80000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT count(*) , avg(SurfaceArea) FROM country WHERE Continent = 'North America' AND SurfaceArea > 3000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT count(*) , avg(SurfaceArea) FROM country WHERE Continent = 'North America' AND SurfaceArea > 3000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT DISTINCT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT Name FROM city WHERE Population BETWEEN 160000 AND 900000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage GROUP BY CountryCode ORDER BY (Percentage) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT Language FROM countrylanguage GROUP BY CountryCode ORDER BY (COUNT(*) DESC) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT country.name , countrylanguage.CountryCode , language , max(percentage) FROM country JOIN countrylanguage ON country.code = countrylanguage.countrycode GROUP BY countrylanguage.CountryCode;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT Code2 , Language FROM countrylanguage GROUP BY CountryCode;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE Language = 'Spanish' GROUP BY CountryCode HAVING Percentage > (SELECT avg(Percentage) FROM countrylanguage WHERE Language = 'Spanish')}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT country.Code) FROM countrylanguage WHERE Language = 'Spanish' AND IsOfficial = 'T'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT Code FROM countrylanguage WHERE Language = 'Spanish' GROUP BY CountryCode ORDER BY Percentage DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT Code FROM countrylanguage WHERE Language = 'Spanish' AND IsOfficial = 'T' GROUP BY CountryCode HAVING SUM(Percentage) > 50;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Age;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT Name FROM conductor WHERE Nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company , Year_of_Founded FROM orchestra ORDER BY Year_of_Founded DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE Type != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE Type != \"Live final\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT COUNT(DISTINCT Nationality) FROM conductor;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT COUNT(DISTINCT Nationality) FROM conductor;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT Name FROM conductor GROUP BY Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT Name FROM conductor GROUP BY Conductor_ID ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.Name , COUNT(*) FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.Conductor_ID , T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID HAVING COUNT(DISTINCT T1.Orchestra_ID) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Conductor_ID FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID HAVING COUNT(DISTINCT T2.Orchestra_ID) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Conductor_ID , T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Conductor_ID , T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T1.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.Conductor_ID , T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE T2.Year_of_Founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT DISTINCT T2.Name FROM orchestra AS T1 JOIN conductor AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE T1.Year_of_Founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT conductor_id , COUNT(*) FROM orchestra GROUP BY conductor_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT TYPE FROM performance GROUP BY TYPE ORDER BY COUNT(*) ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) DESC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra.Orchestra FROM orchestra WHERE orchestra.Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT Orchestra_ID FROM orchestra WHERE Conductor_ID NOT IN (SELECT Conductor_ID FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT T1.Show_ID FROM performance AS T1 JOIN orchestra AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID JOIN show AS T3 ON T1.Show_ID = T3.Performance_ID WHERE T2.Year_of_Founded < 2003 INTERSECT SELECT T1.Show_ID FROM performance AS T1 JOIN orchestra AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID JOIN show AS T3 ON T1.Show_ID = T3.Performance_ID WHERE T2.Year_of_Founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT COUNT(DISTINCT orchestra.Orchestra_ID) FROM orchestra WHERE orchestra.Year_of_Founded <= 2010 AND Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT COUNT(DISTINCT orchestra.Orchestra_ID) FROM orchestra JOIN performance ON orchestra.Orchestra_ID = performance.Orchestra_ID WHERE performance.Type = \"CD\" OR performance.Type = \"DVD\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT Year_of_Founded FROM orchestra WHERE Orchestra_ID IN (SELECT Orchestra_ID FROM performance GROUP BY Orchestra_ID HAVING COUNT(Performance_ID) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT Year_of_Founded FROM orchestra WHERE Orchestra_ID IN (SELECT Orchestra_ID FROM performance GROUP BY Orchestra_ID HAVING COUNT(*) > 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM Highschooler;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM Highschooler;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM Highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT grade FROM Highschooler;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT grade FROM Highschooler;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM Highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM Highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT grade, count(*) FROM Highschooler GROUP BY grade;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT student_id, friend_id FROM Friend;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT T1.id , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.friend_id GROUP BY T2.friend_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.friend_id GROUP BY T2.friend_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT name FROM highschooler WHERE id IN (SELECT student_id FROM friend GROUP BY student_id HAVING count(*) >= 3);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT name FROM highschooler WHERE id IN (SELECT student_id FROM friend GROUP BY student_id HAVING count(*) >= 3);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM Friend WHERE T2.id IN (SELECT T1.friend_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.friend_id = T2.id WHERE T2.name = 'Kyle') AND T1.student_id != (SELECT id FROM Highschooler WHERE name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T2.name FROM Friend JOIN Highschooler AS T2 ON T2.id = friend_id WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Friend WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM Friend WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM Highschooler WHERE ID NOT IN (SELECT student_id FROM Friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM Highschooler WHERE ID NOT IN (SELECT student_id FROM Friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM Friend WHERE student_id IN (SELECT student_id FROM Likes WHERE student_id NOT IN (SELECT liked_id FROM Likes)) INTERSECT SELECT student_id FROM Likes WHERE student_id NOT IN (SELECT liked_id FROM Likes) UNION SELECT student_id FROM Likes WHERE student_id IN (SELECT liked_id FROM Likes) INTERSECT SELECT student_id FROM Friend WHERE student_id NOT IN (SELECT friend_id FROM Friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM Friend WHERE student_id IN (SELECT student_id FROM Likes) AND friend_id IN (SELECT student_id FROM Likes) INTERSECT SELECT student_id FROM Likes WHERE student_id IN (SELECT student_id FROM Friend) AND liked_id IN (SELECT friend_id FROM Friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id IN (SELECT student_id FROM friend UNION SELECT student_id FROM likes) INTERSECT SELECT name FROM highschooler WHERE id IN (SELECT liked_id FROM likes) INTERSECT SELECT name FROM highschooler WHERE id IN (SELECT friend_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id IN (SELECT student_id FROM friend UNION SELECT student_id FROM likes) INTERSECT SELECT name FROM highschooler WHERE id IN (SELECT friend_id FROM friend UNION SELECT liked_id FROM likes)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id, count(*) FROM Likes GROUP BY student_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id, count(*) FROM Likes GROUP BY student_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , COUNT(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T1.id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM Highschooler AS T1 JOIN Likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT name FROM highschooler WHERE id IN (SELECT student_id FROM likes GROUP BY student_id HAVING count(*) >= 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT name FROM highschooler WHERE id IN (SELECT student_id FROM likes GROUP BY student_id HAVING count(*) >= 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT name FROM highschooler WHERE grade > 5 AND id IN (SELECT student_id FROM friend GROUP BY student_id HAVING count(*) >= 2);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT name FROM highschooler WHERE grade > 5 INTERSECT SELECT name FROM highschooler WHERE id IN (SELECT student_id FROM friend GROUP BY student_id HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(DISTINCT liked_id) FROM Likes WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(DISTINCT liked_id) FROM Likes WHERE student_id IN (SELECT id FROM Highschooler WHERE name = 'Kyle');", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(grade) FROM highschooler WHERE id IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(grade) FROM highschooler WHERE id IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM Highschooler WHERE ID NOT IN (SELECT student_id FROM Friend);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Owners WHERE owner_id IN (SELECT owner_id FROM Dogs) INTERSECT SELECT state FROM Professionals WHERE role_code = 'Guardian' INTERSECT SELECT state FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = \"guardian\" INTERSECT SELECT state FROM Professionals WHERE role_code = \"veterinarian\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs WHERE dog_id IN (SELECT dog_id FROM treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(age) FROM dogs WHERE dog_id IN (SELECT dog_id FROM treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT cell_number , last_name , state FROM professionals WHERE state = 'Indiana' OR professional_id IN (SELECT professional_id FROM treatments GROUP BY professional_id HAVING count(*) > 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT cell_number, last_name FROM Professionals WHERE state = 'Indiana' OR role_code = 'veterinarian' GROUP BY professional_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code WHERE T3.treatment_type_description = \"health-care\" AND T2.cost_of_treatment > 1000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT name FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = 'veterinarian' OR role_code = 'guardian' EXCEPT SELECT name FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id, role_code, email_address FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments WHERE treatment_type_code = \"medical care\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id, role_code, email_address FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments WHERE treatment_type_code = \"vaccination\" OR treatment_type_code = \"surgery\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT owner_id , first_name , last_name FROM Owners GROUP BY owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING COUNT(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.first_name , T1.role_code FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM breeds JOIN dogs ON dogs.breed_code = breeds.breed_code GROUP BY dogs.breed_code ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT breed_name FROM breeds JOIN dogs ON dogs.breed_code = breeds.breed_code GROUP BY breed_name ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.last_name FROM Treatments AS T1 JOIN Owners AS T2 ON T1.dog_id -> Dogs.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , O1.last_name FROM Treatments AS T1 JOIN Owners AS O1 ON T1.dog_id = O1.owner_id GROUP BY T1.owner_id ORDER BY sum(T1.cost_of_treatment) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT treatment_type_description , sum(cost_of_treatment) FROM treatments GROUP BY treatment_type_code ORDER BY sum(cost_of_treatment) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T2.treatment_type_description , T1.cost_of_treatment FROM Treatments AS T1 JOIN Treatment_Types AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T1.cost_of_treatment = ( SELECT min(T1.cost_of_treatment) FROM Treatments AS T1 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY sum(T2.weight) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.zip_code , T1.owner_id FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT professional_id , cell_number FROM Treatments GROUP BY professional_id HAVING COUNT(DISTINCT treatment_type_code) >= 2 JOIN Professionals ON Treatments.professional_id = Professionals.professional_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT cell_number , professional_id FROM Professionals WHERE professional_id IN (SELECT professional_id FROM Treatments GROUP BY professional_id , treatment_type_code HAVING count(*) >= 2) INTERSECT SELECT cell_number , professional_id FROM Professionals WHERE professional_id IN (SELECT professional_id FROM Treatments GROUP BY professional_id , treatment_type_code HAVING count(*) >= 2) AND professional_id IN (SELECT professional_id FROM Treatments GROUP BY professional_id , treatment_type_code HAVING count(*) >= 2) AND professional_id IN (SELECT professional_id FROM Treatments GROUP BY professional_id , treatment_type_code HAVING count(*) >= 2)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments) GROUP BY T1.professional_id ORDER BY T1.last_name LIMIT 10;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id WHERE T1.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T.date_of_treatment , Professionals.first_name FROM Treatments AS T JOIN Professionals ON T.professional_id = Professionals.professional_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T.date_of_treatment , Professionals.first_name FROM Treatments AS T JOIN Professionals ON T.professional_id = Professionals.professional_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_description FROM Treatments JOIN Treatment_Types ON Treatments.treatment_type_code = Treatment_Types.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T2.cost_of_treatment , T1.treatment_type_description FROM Treatment_Types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id JOIN Breeds AS T3 ON T1.breed_code = T3.breed_code ORDER BY T3.breed_name LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T1.date_of_birth FROM Dogs AS T1 JOIN Breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.name , T2.first_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = \"Virginia\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"medical\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE dog_id IN (SELECT dog_id FROM Treatments WHERE treatment_type_code = \"Health Care\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT min(age) FROM dogs )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id ORDER BY T2.age LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM Professionals WHERE state = \"Hawaii\" OR state = \"Wisconsin\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived, date_departed FROM Dogs WHERE gender = 'F'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.dog_id) FROM Treatments AS T1 JOIN Treatment_Types AS T2 ON T1.treatment_type_code = T2.treatment_type_code WHERE T2.treatment_type_description = 'Health Care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM TREATMENTS WHERE treatment_type_code = \"health care\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT T1.professional_id) FROM Treatments AS T1 JOIN Dogs AS D2 ON T1.dog_id = D2.dog_id JOIN Breeds AS B ON D2.breed_code = B.breed_code WHERE B.breed_name = 'Puppy' AND T1.treatment_type_code = 'Vet'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(DISTINCT professional_id) FROM treatments WHERE treatment_type_code = 'Puppies';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name, last_name, email_address FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name, last_name, email_address FROM Owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(cost_of_treatment) FROM Treatments;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN (SELECT dog_id FROM Treatments);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(DISTINCT dog_id) FROM treatments WHERE treatment_type_code = 'Health-care';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN (SELECT owner_id FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN (SELECT owner_id FROM Dogs WHERE date_departed != \"empty\");", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments WHERE treatment_type_code IN (SELECT treatment_type_code FROM Treatment_Types WHERE treatment_type_description = 'puppies'))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN (SELECT professional_id FROM Treatments WHERE treatment_type_code = \"puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = '1'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type, charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT max(charge_amount) FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM Charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address, home_phone, cell_number FROM Professionals WHERE role_code = 'veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address, home_phone, cell_number FROM Professionals;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT breed_code , size_code FROM Dogs UNION SELECT breed_code , size_code FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT breed_code , size_code FROM Dogs;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T.professional_id , professionals.first_name , treatment_types.treatment_type_description FROM treatments AS T JOIN professionals ON T.professional_id = professionals.professional_id JOIN treatment_types ON T.treatment_type_code = treatment_types.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT Professionals.first_name , Treatment_Types.treatment_type_description FROM Professionals JOIN Treatments ON Professionals.professional_id = Treatments.professional_id JOIN Treatment_Types ON Treatments.treatment_type_code = Treatment_Types.treatment_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT COUNT(*) FROM singer WHERE Citizenship = \"Vocalist\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT name FROM singer ORDER BY net_worth_millions ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year, Citizenship FROM singer;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != 'French'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship, COUNT(*) FROM singer GROUP BY Citizenship;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship, max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT title , name FROM song JOIN singer ON song.singer_id = singer.singer_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT title , singer.name FROM song JOIN singer ON song.singer_id = singer.singer_id;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.name FROM singer AS T1 JOIN song AS T2 ON T1.singer_id = T2.singer_id WHERE T2.sales > 300000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID HAVING COUNT(DISTINCT T2.Title) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT DISTINCT T1.name FROM singer AS T1 JOIN song AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id HAVING count(*) > 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T1.Name, sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Singer_ID;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T1.Name, SUM(T1.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT name FROM singer WHERE singer_id NOT IN (SELECT singer_id FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(DISTINCT feature_id) FROM Other_Property_Features;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT feature_type_code FROM Other_Available_Features WHERE feature_name = \"AirCon\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT Ref_Property_Types.property_type_description FROM Ref_Property_Types JOIN Properties ON Ref_Property_Types.property_type_code = Properties.property_type_code;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT property_name FROM properties WHERE property_type_code = 'House' AND room_count > 1 OR property_type_code = 'Apartment' AND room_count > 1;", + "success": true, + "error": null + } +] \ No newline at end of file diff --git a/infer/qwen/spider_syn/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json b/infer/qwen/spider_syn/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json new file mode 100644 index 0000000000000000000000000000000000000000..d5dbc13af45157d6b4477d0c1f149b4c59168907 --- /dev/null +++ b/infer/qwen/spider_syn/srkl_train_0.6b_4b_spider_lora__ckpt1090__test__full_sql_result.json @@ -0,0 +1,11376 @@ +[ + { + "sample_id": "spider_syn:test:0", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many vocalists do we have?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the total number of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:2", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show name, nationality, age for all vocalists ordered by age from the oldest to the youngest.", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:3", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, nationalities, and ages for every musicians in descending order of age?", + "gold_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "pred_sql": "SELECT name , country , age FROM singer ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:4", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age of all vocalists from France?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:5", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average, minimum, and maximum age for all French musicians?", + "gold_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "pred_sql": "SELECT avg(age) , min(age) , max(age) FROM singer WHERE country = 'France'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:6", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and the publish year of the song by the youngest vocalists.", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT name , song_release_year FROM singer ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:7", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and publish years for all the songs of the youngest musicians?", + "gold_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age LIMIT 1", + "pred_sql": "SELECT song_name , song_release_year FROM singer ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:8", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all distinct nationalities where vocalists above age 20 are from?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:9", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the different nationalities with musicians above age 20?", + "gold_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "pred_sql": "SELECT DISTINCT country FROM singer WHERE age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:10", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show all State and the number of vocalists in each country.", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:11", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many musicians are from each State?", + "gold_sql": "SELECT country , count(*) FROM singer GROUP BY country", + "pred_sql": "SELECT count(*) , state FROM musician GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:12", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all music titles by vocalists above the average age.", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:13", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are all the music titles by musicians who are older than average?", + "gold_sql": "SELECT song_name FROM singer WHERE age > (SELECT avg(age) FROM singer)", + "pred_sql": "SELECT Song_Name FROM singer WHERE Age > (SELECT avg(Age) FROM singer)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:14", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show position and name for all stadiums with number of seats between 5000 and 10000.", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT position , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:15", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the addresses and names of all stations with number of seats between 5000 and 10000?", + "gold_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "pred_sql": "SELECT LOCATION , name FROM stadium WHERE capacity BETWEEN 5000 AND 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:16", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and the maximum seats of all stadiums?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:17", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the average and maximum seats for all stations?", + "gold_sql": "SELECT avg(capacity) , max(capacity) FROM stadium", + "pred_sql": "SELECT avg(Average) , max(Average) FROM stadium", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:18", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:19", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats for the stadium with the highest average attendance?", + "gold_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "pred_sql": "SELECT name , capacity FROM stadium ORDER BY average DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:20", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows are there in year 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:21", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "How many shows occurred in 2014 or 2015?", + "gold_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "pred_sql": "SELECT count(*) FROM concert WHERE YEAR = 2014 OR YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:22", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and the number of shows in each stadium.", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT T1.name , count(*) FROM stadium AS T1 JOIN concert AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T2.stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:23", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "For each stadium, how many shows play there?", + "gold_sql": "SELECT T2.name , count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id GROUP BY T1.stadium_id", + "pred_sql": "SELECT count(*) , stadium_id FROM concert GROUP BY stadium_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:24", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium name and number of seats with most number of shows in year 2014 or after.", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T1.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:25", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and number of seats of the stadium with the most shows after 2013?", + "gold_sql": "SELECT T2.name , T2.capacity FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year >= 2014 GROUP BY T2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.capacity FROM stadium AS t1 JOIN concert AS t2 ON t1.stadium_id = t2.stadium_id WHERE t2.year > 2013 GROUP BY t2.stadium_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:26", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Which year has most number of shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:27", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the time that had the most shows?", + "gold_sql": "SELECT YEAR FROM concert GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Year FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.Year ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:28", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the stadium names without any shows.", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:29", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the stadiums without any shows?", + "gold_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:30", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show States where a singer above age 40 and a singer below 30 are from.", + "gold_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "pred_sql": "SELECT country FROM singer WHERE age > 40 INTERSECT SELECT country FROM singer WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:31", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show names for all stadiums except for stadiums having a shows in year 2014.", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:32", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of all stadiums that did not have a shows in 2014?", + "gold_sql": "SELECT name FROM stadium EXCEPT SELECT T2.name FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.year = 2014", + "pred_sql": "SELECT name FROM stadium WHERE stadium_id NOT IN (SELECT stadium_id FROM concert WHERE YEAR = 2014)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:33", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Show the name and theme for all shows and the number of vocalists in each shows.", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T1.Name , T1.theme , count(*) FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_ID = T2.concert_ID GROUP BY T1.name , T1.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:34", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names, themes, and number of singers for each and every show?", + "gold_sql": "SELECT T2.concert_name , T2.theme , count(*) FROM singer_in_concert AS T1 JOIN concert AS T2 ON T1.concert_id = T2.concert_id GROUP BY T2.concert_id", + "pred_sql": "SELECT T3.name , T2.theme , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T2.concert_id = T3.concert_id GROUP BY T2.theme", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:35", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List singer names and number of shows for each musicians.", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:36", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the singers and number of shows for each person?", + "gold_sql": "SELECT T2.name , count(*) FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id GROUP BY T2.singer_id", + "pred_sql": "SELECT T1.name , count(*) FROM singer AS T1 JOIN singer_in_concert AS T2 ON T1.singer_id = T2.singer_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:37", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "List all vocalist names in shows in year 2014.", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:38", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names of the musicians who performed in a musical performance in 2014?", + "gold_sql": "SELECT T2.name FROM singer_in_concert AS T1 JOIN singer AS T2 ON T1.singer_id = T2.singer_id JOIN concert AS T3 ON T1.concert_id = T3.concert_id WHERE T3.year = 2014", + "pred_sql": "SELECT T3.name FROM concert AS T1 JOIN singer_in_concert AS T2 ON T1.concert_id = T2.concert_id JOIN singer AS T3 ON T2.singer_id = T3.singer_id WHERE T1.year = 2014", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:39", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "what is the name and nation of the vocalist who have a song having 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:40", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What is the name and nationality of origin of every musicians who has a song with the word 'Hey' in its title?", + "gold_sql": "SELECT name , country FROM singer WHERE song_name LIKE '%Hey%'", + "pred_sql": "SELECT name , country FROM singer WHERE song_name LIKE \"%Hey%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:41", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the name and position of the stadiums which some musical performances happened in the years of both 2014 and 2015.", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.position FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T2.name , T2.position FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:42", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the names and addresses of the stadiums that had musical performances that occurred in both 2014 and 2015?", + "gold_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T1.Year = 2015", + "pred_sql": "SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2014 INTERSECT SELECT T2.name , T2.location FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE YEAR = 2015", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:43", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "Find the number of musical performances happened in the stadium with the highest number of seats.", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.capacity DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:44", + "benchmark": "spider_syn", + "split": "test", + "db_id": "concert_singer", + "question": "What are the number of musical performances that occurred in the stadium with the largest number of seats?", + "gold_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id ORDER BY T2.Capacity DESC LIMIT 1", + "pred_sql": "SELECT count(*) FROM concert AS T1 JOIN stadium AS T2 ON T1.stadium_id = T2.stadium_id WHERE T2.capacity = (SELECT max(capacity) FROM stadium)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:45", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals who is heavier than 10.", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:46", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals heavier than 10?", + "gold_sql": "SELECT count(*) FROM pets WHERE weight > 10", + "pred_sql": "SELECT count(*) FROM Pets WHERE weight > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:47", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the weight of the youngest puppy.", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:48", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How much does the youngest puppy weigh?", + "gold_sql": "SELECT weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT weight FROM Pets ORDER BY pet_age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:49", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the maximum weight for each category of pet. List the maximum weight and pet category.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:50", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "List the maximum weight and category for each species of domestic animals.", + "gold_sql": "SELECT max(weight) , petType FROM pets GROUP BY petType", + "pred_sql": "SELECT max(weight) , pettype FROM Pets WHERE pettype = 'domestic' GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:51", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find number of animals owned by students who are older than 20.", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:52", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many animals are owned by students that have an age greater than 20?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.age > 20", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T1.age > 20", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:53", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of puppies that are raised by female students (with gender F).", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.F = \"F\" JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:54", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many puppies are raised by female students?", + "gold_sql": "SELECT count(*) FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T2.petid = T3.petid WHERE T1.sex = 'F' AND T3.pettype = 'dog'", + "pred_sql": "SELECT count(*) FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.sex = 'F' JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:55", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of distinct species of domestic animals.", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT species) FROM domestic_animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:56", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "How many different species of animals are there?", + "gold_sql": "SELECT count(DISTINCT pettype) FROM pets", + "pred_sql": "SELECT count(DISTINCT name) FROM Animals", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:57", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name of students who have kitten or puppy pet.", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT T2.Fname , T2.Lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:58", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the given names of every student who has a kitten or puppy as a pet?", + "gold_sql": "SELECT DISTINCT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' OR T3.pettype = 'dog'", + "pred_sql": "SELECT DISTINCT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\" OR T3.PetType = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:59", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the name of students who have both kitten and puppy pets.", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:60", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the students' given names who have both kittens and puppies as pets?", + "gold_sql": "SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat' INTERSECT SELECT T1.Fname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog'", + "pred_sql": "SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Kitten\" INTERSECT SELECT T1.fname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"Puppy\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:61", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the major and age of students who do not have a kitten pet.", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT major , age FROM Student EXCEPT SELECT T1.major , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.PetType = \"Kitten\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:62", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What discipline is every student who does not own a kitten as a pet, and also how old are they?", + "gold_sql": "SELECT major , age FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1 Discipline , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID EXCEPT SELECT T1 Discipline , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:63", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of students who do not have a kitten pet.", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:64", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the ids of the students who do not own kittens as pets?", + "gold_sql": "SELECT stuid FROM student EXCEPT SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat'", + "pred_sql": "SELECT StuID FROM Student EXCEPT SELECT StuID FROM Has_Pet", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:65", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a puppy but do not have a cat as a pet.", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Pug\" EXCEPT SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:66", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name of every student who has a dog but does not have a kitten?", + "gold_sql": "SELECT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'dog' AND T1.stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pettype = 'cat')", + "pred_sql": "SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"dog\" EXCEPT SELECT T1.fname , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.PetID = T3.PetID WHERE T3.pettype = \"cat\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:67", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the category and weight of the youngest pet.", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pet_type , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:68", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What species of animal is the youngest animal, and how much does it weigh?", + "gold_sql": "SELECT pettype , weight FROM pets ORDER BY pet_age LIMIT 1", + "pred_sql": "SELECT pettype , weight FROM Pets ORDER BY pet_age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:69", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id and weight of all animals whose age is older than 1.", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:70", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id and weight of every animals who is older than 1?", + "gold_sql": "SELECT petid , weight FROM pets WHERE pet_age > 1", + "pred_sql": "SELECT petid , weight FROM Pets WHERE petage > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:71", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average and maximum age for each species of animal.", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT avg(age) , max(age) , pettype FROM Pets GROUP BY pettype", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:72", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average and maximum age for each pet species?", + "gold_sql": "SELECT avg(pet_age) , max(pet_age) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(pet_age) , max(pet_age) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:73", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average weight for each pet category.", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT PetType , avg(weight) FROM Pets GROUP BY PetType", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:74", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average weight for each species of pet?", + "gold_sql": "SELECT avg(weight) , pettype FROM pets GROUP BY pettype", + "pred_sql": "SELECT pet_type , avg(weight) FROM Pets GROUP BY pet_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:75", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and age of students who have a pet.", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT T1.fname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T2.petid = T3.petid WHERE T3.pettype = \"Mammal\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:76", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What are the different given names and ages of the students who do have pets?", + "gold_sql": "SELECT DISTINCT T1.fname , T1.age FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid", + "pred_sql": "SELECT DISTINCT T1.lname , T1.age FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:77", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the id of the animals owned by student whose family name is 'Smith'.", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Fname = \"Tom\" AND T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:78", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the id of the animals owned by the student whose family name is 'Smith'?", + "gold_sql": "SELECT T2.petid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid WHERE T1.Lname = 'Smith'", + "pred_sql": "SELECT T1.StuID FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.StuID = T2.StuID WHERE T1.Fname = \"Tom\" AND T1.Lname = \"Smith\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:79", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the number of animals for each student who has any pet and student id.", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:80", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "For students who have pets, how many animals does each student have?", + "gold_sql": "SELECT count(*) , T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid", + "pred_sql": "SELECT count(*) , StuID FROM Has_Pet GROUP BY StuID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:81", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the given name and gender of student who have more than one pet.", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T1.fname , T1.sex , T1.lname FROM Student AS T1 JOIN Has_Pet AS T2 ON T1.Stuid = T2.Stuid GROUP BY T1.Stuid HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:82", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the given name and gender of the all the students who have more than one pet?", + "gold_sql": "SELECT T1.fname , T1.sex FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid GROUP BY T1.stuid HAVING count(*) > 1", + "pred_sql": "SELECT T2.Fname , T2.Sex FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID GROUP BY T1.StuID HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:83", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the family name of the student who has a kitten that is age 3.", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.Lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:84", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the family name of the student who has a kitten that is 3 years old?", + "gold_sql": "SELECT T1.lname FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid JOIN pets AS T3 ON T3.petid = T2.petid WHERE T3.pet_age = 3 AND T3.pettype = 'cat'", + "pred_sql": "SELECT T2.Lname FROM Has_Pet AS T1 JOIN Student AS T2 ON T1.StuID = T2.StuID JOIN Pets AS T3 ON T1.PetID = T3.PetID WHERE T3.pet_age = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:85", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "Find the average age of students who do not have any pet.", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:86", + "benchmark": "spider_syn", + "split": "test", + "db_id": "pets_1", + "question": "What is the average age for all students who do not own any pets?", + "gold_sql": "SELECT avg(age) FROM student WHERE stuid NOT IN (SELECT T1.stuid FROM student AS T1 JOIN has_pet AS T2 ON T1.stuid = T2.stuid)", + "pred_sql": "SELECT avg(age) FROM Student WHERE StuID NOT IN (SELECT StuID FROM Has_Pet)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:87", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many continents are there?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:88", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of continents?", + "gold_sql": "SELECT count(*) FROM CONTINENTS;", + "pred_sql": "SELECT count(*) FROM continents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:89", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States does each continent have? List the continent id, continent name and the number of nations.", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT T2.ContId , T2.Continent , count(*) FROM countries AS T1 JOIN continents AS T2 ON T1.Continent = T2.ContId GROUP BY T2.ContId", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:90", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For each continent, list its id, name, and how many States it has?", + "gold_sql": "SELECT T1.ContId , T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId;", + "pred_sql": "SELECT countid , continent , count(*) FROM continents GROUP BY continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:91", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States are listed?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM cars_data", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:92", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many countries exist?", + "gold_sql": "SELECT count(*) FROM COUNTRIES;", + "pred_sql": "SELECT count(*) FROM countries", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:93", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many models does each car manufacturer produce? List manufacturer full name, id and the number.", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , COUNT(*) , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.Maker GROUP BY T1.Maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:94", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the full name of each car manufacturer, along with its id and how many models it produces?", + "gold_sql": "SELECT T1.FullName , T1.Id , count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id;", + "pred_sql": "SELECT T1.Maker , T1.id , count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:95", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model of the vehicle has the minimum horsepower?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:96", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model of the vehicle with the smallest amount of power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.horsepower ASC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY horsepower LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:97", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the model of the vehicle who is lighter than the average.", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT model FROM cars_data WHERE weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:98", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the model for the vehicle with a weight smaller than the average?", + "gold_sql": "SELECT T1.model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Weight < (SELECT avg(Weight) FROM CARS_DATA)", + "pred_sql": "SELECT T1.Model FROM model_list AS T1 JOIN cars_data AS T2 ON T1.id = T2.id WHERE T2.weight < (SELECT avg(weight) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:99", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the name of the manufacturer that produced some vehicles in the year of 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT maker FROM car_makers WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:100", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the different car manufacturers who produced a vehicle in 1970?", + "gold_sql": "SELECT DISTINCT T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model JOIN CARS_DATA AS T4 ON T3.MakeId = T4.id WHERE T4.year = '1970';", + "pred_sql": "SELECT DISTINCT T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.id = T2.modelid WHERE YEAR = 1970", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:101", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Find the make and production time of the vehicles that were produced in the earliest year?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t2.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.id ORDER BY t2.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:102", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the manufacturer of the vehicle produced in the earliest year and what year was it?", + "gold_sql": "SELECT T2.Make , T1.Year FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Year = (SELECT min(YEAR) FROM CARS_DATA);", + "pred_sql": "SELECT t1.maker , t1.year FROM car_makers AS t1 JOIN cars_data AS t2 ON t1.id = t2.id ORDER BY t2.year LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:103", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinct vehicle models are the produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.makeid = T2.makeid WHERE T1.year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:104", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models for the vehicles produced after 1980?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.model = T2.model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.id WHERE T3.year > 1980;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_names AS T2 ON T1.MakeId = T2.Model WHERE T1.Year > 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:105", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many car manufacturers are there in each continents? List the continent name and the count.", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T2.Continent , count(*) FROM car_makers AS T1 JOIN continents AS T2 ON T1.Country = T2.ContId GROUP BY T2.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:106", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of each continent and how many vehicle manufacturers are there in each one?", + "gold_sql": "SELECT T1.Continent , count(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.continent JOIN car_makers AS T3 ON T2.CountryId = T3.Country GROUP BY T1.Continent;", + "pred_sql": "SELECT T1.Continent , count(*) FROM continents AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Country JOIN countries AS T3 ON T3.CountryId = T2.Country GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:107", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which of the States has the most car manufacturers? List the State name.", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.StateName FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:108", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the name of the State with the most vehicle manufacturers?", + "gold_sql": "SELECT T2.CountryName FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId GROUP BY T1.Country ORDER BY Count(*) DESC LIMIT 1;", + "pred_sql": "SELECT t1.fullname FROM car_makers AS t1 JOIN countries AS t2 ON t1.country = t2.countryid GROUP BY t1.country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:109", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced by each manufacturer? List the count and the manufacturer full name.", + "gold_sql": "SELECT Count(*) , T2.FullName FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.fullname FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:110", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicle models that are produced by each manufacturer and what is the id and full name of each manufacturer?", + "gold_sql": "SELECT Count(*) , T2.FullName , T2.id FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id GROUP BY T2.id;", + "pred_sql": "SELECT count(*) , T1.id , T1.fullname FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:111", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the accelerate of the vehicle make amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T4.Accelerate FROM car_makers AS T1 JOIN model_list AS T2 ON T1.Id = T2.Maker JOIN car_names AS T3 ON T2.Model = T3.Model JOIN cars_data AS T4 ON T3.Make = T4.MakeId WHERE T1.FullName = \"Amc hornet sportabout (sw)\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:112", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How much does the vehicle accelerate that makes out amc hornet sportabout (sw)?", + "gold_sql": "SELECT T1.Accelerate FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Make = 'amc hornet sportabout (sw)';", + "pred_sql": "SELECT T1.Accelerate FROM cars_data AS T1 JOIN car_names AS T2 ON T1.Id = T2.MakeId JOIN model_list AS T3 ON T2.Model = T3.Model WHERE T3.Maker = 'AMC' AND T2.Make = 'Hornet Sportabout'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:113", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many French car manufacturers are there?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE fullname LIKE \"%French%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:114", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of manufacturers of vehicle in France?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN COUNTRIES AS T2 ON T1.Country = T2.CountryId WHERE T2.CountryName = 'france';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.country = T2.countryid WHERE T2.countryname = \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:115", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicle models are produced in the usa?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN countries AS T2 ON T1.id = T2.countryid WHERE T2.countryname = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:116", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the count of the vehicle models produced in the United States?", + "gold_sql": "SELECT count(*) FROM MODEL_LIST AS T1 JOIN CAR_MAKERS AS T2 ON T1.Maker = T2.Id JOIN COUNTRIES AS T3 ON T2.Country = T3.CountryId WHERE T3.CountryName = 'usa';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker JOIN countries AS T3 ON T3.countryid = T1.countryid WHERE T3.countryname = \"United States\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:117", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon(mpg) of the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:118", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average miles per gallon of all the cars with 4 cylinders?", + "gold_sql": "SELECT avg(mpg) FROM CARS_DATA WHERE Cylinders = 4;", + "pred_sql": "SELECT avg(MPG) FROM cars_data WHERE Cylinders = 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:119", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the smallest weight of the car produced with 8 cylinders on 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT Weight FROM cars_data WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:120", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the minimu weight of the car with 8 cylinders produced in 1974?", + "gold_sql": "SELECT Weight FROM CARS_DATA WHERE Cylinders = 8 AND YEAR = 1974 ORDER BY Weight ASC LIMIT 1;", + "pred_sql": "SELECT min(weight) FROM cars_data WHERE cylinders = 8 AND YEAR = 1974", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:121", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are all the companies and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:122", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the manufacturers and models?", + "gold_sql": "SELECT Maker , Model FROM MODEL_LIST;", + "pred_sql": "SELECT T1.Maker , T2.Model FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:123", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the States having at least one vehicle manufacturer? List name and id.", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.FullName , T1.Id FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Maker = T2.MakeId GROUP BY T1.Maker HAVING COUNT(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:124", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all States with at least one vehicle manufacturer?", + "gold_sql": "SELECT T1.CountryName , T1.CountryId FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) >= 1;", + "pred_sql": "SELECT T1.Continent , T1.Id FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id GROUP BY T1.Id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:125", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of the vehicle with power more than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT id FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:126", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with a power greater than 150?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE horsepower > 150;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE Horsepower > 150", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:127", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight of vehicles each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT YEAR , avg(weight) FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:128", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average weight and year for each year?", + "gold_sql": "SELECT avg(Weight) , YEAR FROM CARS_DATA GROUP BY YEAR;", + "pred_sql": "SELECT avg(weight) , YEAR FROM cars_data GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:129", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which States in europe have at least 3 vehicle manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T2.Continent FROM car_makers AS T1 JOIN countries AS T2 ON T1.Country = T2.CountryId WHERE T1.Maker = \"Ford\" GROUP BY T2.Continent HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:130", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of all European States with at least 3 manufacturers?", + "gold_sql": "SELECT T1.CountryName FROM COUNTRIES AS T1 JOIN CONTINENTS AS T2 ON T1.Continent = T2.ContId JOIN CAR_MAKERS AS T3 ON T1.CountryId = T3.Country WHERE T2.Continent = 'europe' GROUP BY T1.CountryName HAVING count(*) >= 3;", + "pred_sql": "SELECT T1.FullName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.country WHERE T1.Continent = \"Europe\" GROUP BY T1.CountryName HAVING COUNT(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:131", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum power and the manufacturer of the vehicle models with 3 cylinders?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T2.cylinders = 3 GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:132", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the largest amount of power for the models with 3 cylinders and what manufacturer is it?", + "gold_sql": "SELECT T2.horsepower , T1.Make FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.cylinders = 3 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT max(horsepower) , T1.maker FROM cars_data AS T1 JOIN model_list AS T2 ON T1.id = T2.model WHERE T1.cylinders = 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:133", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model saves the most gasoline? That is to say, have the maximum miles per gallon.", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT model FROM cars_data ORDER BY mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:134", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the automobile model with the highest mpg?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id ORDER BY T2.mpg DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.id = t2.makeid ORDER BY t1.mpg DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:135", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power of the automobile before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:136", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average power for all automobiles produced before 1980?", + "gold_sql": "SELECT avg(horsepower) FROM CARS_DATA WHERE YEAR < 1980;", + "pred_sql": "SELECT avg(Horsepower) FROM cars_data WHERE YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:137", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl of the automobile of model volvo?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(Edispl) FROM cars_data WHERE model = 'volvo'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:138", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the average edispl for all volvos?", + "gold_sql": "SELECT avg(T2.edispl) FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T1.Model = 'volvo';", + "pred_sql": "SELECT avg(edispl) FROM cars_data WHERE make = \"Volvo\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:139", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for different number of cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT Cylinders , max(Accelerate) FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:140", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum accelerate for all the different cylinders?", + "gold_sql": "SELECT max(Accelerate) , Cylinders FROM CARS_DATA GROUP BY Cylinders;", + "pred_sql": "SELECT max(Accelerate) , Cylinders FROM cars_data GROUP BY Cylinders", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:141", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which model has the most version(make) of automobiles?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T2.Maker FROM car_names AS T1 JOIN model_list AS T2 ON T1.Model = T2.Model WHERE T1.Make = (SELECT make FROM cars_data GROUP BY make ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:142", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What model has the most different versions?", + "gold_sql": "SELECT Model FROM CAR_NAMES GROUP BY Model ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT T1.maker FROM car_makers AS T1 JOIN car_names AS T2 ON T1.model = T2.model GROUP BY T1.maker ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:143", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many vehicles have more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:144", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of vehicles with more than 4 cylinders?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE Cylinders > 4;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:145", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "how many automobiles were produced in 1980?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:146", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In 1980, how many automobiles were made?", + "gold_sql": "SELECT count(*) FROM CARS_DATA WHERE YEAR = 1980;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE YEAR = 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:147", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobile models were produced by the manufacturer with full name American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers WHERE maker = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:148", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobile models created by the car manufacturer American Motor Company?", + "gold_sql": "SELECT count(*) FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker WHERE T1.FullName = 'American Motor Company';", + "pred_sql": "SELECT count(*) FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker WHERE T1.fullname = \"American Motor Company\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:149", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which manufacturers designed more than 3 vehicle models? List full name and the id.", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.FullName FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:150", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names and ids of all manufacturers with more than 3 models?", + "gold_sql": "SELECT T1.FullName , T1.Id FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.Maker , T1.id FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) > 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:151", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which distinctive types are produced by manufacturer with the full name General Motors or weighing more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T1.Model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.Id = T2.Id WHERE T2.FullName = \"General Motors\" OR T1.Weight > 3500", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:152", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models created by either the car manufacturer General Motors or weighed more than 3500?", + "gold_sql": "SELECT DISTINCT T2.Model FROM CAR_NAMES AS T1 JOIN MODEL_LIST AS T2 ON T1.Model = T2.Model JOIN CAR_MAKERS AS T3 ON T2.Maker = T3.Id JOIN CARS_DATA AS T4 ON T1.MakeId = T4.Id WHERE T3.FullName = 'General Motors' OR T4.weight > 3500;", + "pred_sql": "SELECT DISTINCT T2.Model FROM cars_data AS T1 JOIN car_makers AS T2 ON T1.MakeId = T2.Id WHERE T1.Weight > 3500 OR T2.Maker = 'General Motors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:153", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "In which years automobiles were produced weighing no less than 3000 and no more than 4000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT YEAR FROM cars_data WHERE weight BETWEEN 3000 AND 4000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:154", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different years in which there were vehicles produced that weighed less than 4000 and also vehicles that weighted more than 3000?", + "gold_sql": "SELECT DISTINCT T1.Year FROM CARS_DATA AS T1 WHERE T1.Weight > 3000 AND T1.weight < 4000;", + "pred_sql": "SELECT DISTINCT YEAR FROM cars_data WHERE weight < 4000 INTERSECT SELECT DISTINCT YEAR FROM cars_data WHERE weight > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:155", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the largest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:156", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the power of the automobile with the greatest accelerate?", + "gold_sql": "SELECT T1.horsepower FROM CARS_DATA AS T1 ORDER BY T1.accelerate DESC LIMIT 1;", + "pred_sql": "SELECT Horsepower FROM cars_data ORDER BY Accelerate DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:157", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For model volvo, how many cylinders does the automobile with the least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT min(cylinders) FROM cars_data WHERE model = 'volvo' AND accelerate = (SELECT min(accelerate) FROM cars_data WHERE model = 'volvo')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:158", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For a volvo model, how many cylinders does the version with least accelerate have?", + "gold_sql": "SELECT count(cylinders) FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = 'volvo' ORDER BY T1.accelerate ASC LIMIT 1;", + "pred_sql": "SELECT Cylinders FROM cars_data WHERE Make = \"Volvo\" ORDER BY Accelerate LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:159", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles have a larger accelerate than the automobile with the largest power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(accelerate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:160", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with a greater accelerate than the one with the most power?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Accelerate > ( SELECT Accelerate FROM CARS_DATA ORDER BY Horsepower DESC LIMIT 1 );", + "pred_sql": "SELECT count(*) FROM cars_data WHERE accelerate > (SELECT max(alculate) FROM cars_data)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:161", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many States has more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(DISTINCT maker) FROM car_makers GROUP BY maker HAVING count(DISTINCT maker) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:162", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of States with more than 2 car manufacturers?", + "gold_sql": "SELECT COUNT(*) FROM ( SELECT T1.CountryId , COUNT(*) FROM COUNTRIES AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.CountryId HAVING count(*) > 2 );", + "pred_sql": "SELECT count(*) FROM car_makers GROUP BY maker HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:163", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "How many automobiles has over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:164", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the number of automobiles with over 6 cylinders?", + "gold_sql": "SELECT COUNT(*) FROM CARS_DATA WHERE Cylinders > 6;", + "pred_sql": "SELECT count(*) FROM cars_data WHERE cylinders > 6", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:165", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For the automobiles with 4 cylinders, which model has the largest power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.id = t2.makeid WHERE t1.cylinders = 4 ORDER BY t1.Horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:166", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "For all of the 4 cylinder automobiles, which model has the most power?", + "gold_sql": "SELECT T1.Model FROM CAR_NAMES AS T1 JOIN CARS_DATA AS T2 ON T1.MakeId = T2.Id WHERE T2.Cylinders = 4 ORDER BY T2.horsepower DESC LIMIT 1;", + "pred_sql": "SELECT t2.model FROM cars_data AS t1 JOIN car_names AS t2 ON t1.id = t2.makeid WHERE t1.cylinders = 4 GROUP BY t2.model ORDER BY t1.horsepower DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:167", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles with more than lowest power, which ones do not have more than 3 cylinders? List the vehicle makeid and manufacturer name.", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders <= 3;", + "pred_sql": "SELECT makeid , fullName FROM car_makers WHERE id NOT IN (SELECT makeid FROM cars_data WHERE horsepower > (SELECT min(horsepower) FROM cars_data)) AND cylinders != 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:168", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Among the automobiles that do not have the minimum power, what are the manufacturer ids and names of al those with less than 4 cylinders?", + "gold_sql": "SELECT T2.MakeId , T2.Make FROM CARS_DATA AS T1 JOIN CAR_NAMES AS T2 ON T1.Id = T2.MakeId WHERE T1.Horsepower > (SELECT min(Horsepower) FROM CARS_DATA) AND T1.Cylinders < 4;", + "pred_sql": "SELECT makeid , fullname FROM car_makers WHERE make != 'Ford' AND cylinders < 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:169", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum miles per gallon of the automobile with 8 cylinders or produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(MPG) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:170", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What is the maximum mpg of the automobiles that had 8 cylinders or that were produced before 1980?", + "gold_sql": "SELECT mpg FROM CARS_DATA WHERE Cylinders = 8 OR YEAR < 1980 ORDER BY mpg DESC LIMIT 1;", + "pred_sql": "SELECT max(mpg) FROM cars_data WHERE cylinders = 8 OR YEAR < 1980", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:171", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which models are lighter than 3500 but not built by the 'Ford Motor Company'?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model JOIN car_makers AS T3 ON T3.id = T2.make WHERE T3.fullname = 'Ford Motor Company'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:172", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the different models wthat are lighter than 3500 but were not built by the Ford Motor Company?", + "gold_sql": "SELECT DISTINCT T1.model FROM MODEL_LIST AS T1 JOIN CAR_NAMES AS T2 ON T1.Model = T2.Model JOIN CARS_DATA AS T3 ON T2.MakeId = T3.Id JOIN CAR_MAKERS AS T4 ON T1.Maker = T4.Id WHERE T3.weight < 3500 AND T4.FullName != 'Ford Motor Company';", + "pred_sql": "SELECT DISTINCT model FROM cars_data WHERE weight < 3500 EXCEPT SELECT DISTINCT T2.model FROM car_names AS T1 JOIN model_list AS T2 ON T1.model = T2.model WHERE T1.make = 'Ford'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:173", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the name of the States where there is not a single automobile maker?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:174", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the names of the States with no vehicle manufacturers?", + "gold_sql": "SELECT CountryName FROM countries EXCEPT SELECT T1.CountryName FROM countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.countryId = T2.Country;", + "pred_sql": "SELECT T1.CountryName FROM countries AS T1 JOIN car_makers AS T2 ON T1.CountryId = T2.Country WHERE T2.Maker = \"none\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:175", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "Which are the automobile manufacturers which produce at least 2 models and more than 3 automobile manufacturers? List the id and the manufacturer.", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:176", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and manufacturers of all automobile manufacturers that produce at least 2 models and make more than 3 automobiles?", + "gold_sql": "SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker GROUP BY T1.Id HAVING count(*) >= 2 INTERSECT SELECT T1.Id , T1.Maker FROM CAR_MAKERS AS T1 JOIN MODEL_LIST AS T2 ON T1.Id = T2.Maker JOIN CAR_NAMES AS T3 ON T2.model = T3.model GROUP BY T1.Id HAVING count(*) > 3;", + "pred_sql": "SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 INTERSECT SELECT T1.id , T1.maker FROM car_makers AS T1 JOIN model_list AS T2 ON T1.id = T2.maker GROUP BY T1.id HAVING count(*) >= 2 AND T1.maker >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:177", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the id and names of the nations which have more than 3 vehicle manufacturers or produce the 'fiat' model?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.id , T1.countryname FROM countries AS T1 JOIN car_makers AS T2 ON T1.countryid = T2.country WHERE count(*) > 3 UNION SELECT T3.id , T3.countryname FROM cars_data AS T3 JOIN car_names AS T4 ON T3.makeid = T4.makeid WHERE T4.model = 'fiat'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:178", + "benchmark": "spider_syn", + "split": "test", + "db_id": "car_1", + "question": "What are the ids and names of all States that either have more than 3 automobile manufacturers or produce fiats?", + "gold_sql": "SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country GROUP BY T1.countryId HAVING count(*) > 3 UNION SELECT T1.countryId , T1.CountryName FROM Countries AS T1 JOIN CAR_MAKERS AS T2 ON T1.CountryId = T2.Country JOIN MODEL_LIST AS T3 ON T2.Id = T3.Maker WHERE T3.Model = 'fiat';", + "pred_sql": "SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId GROUP BY T1.Id HAVING count(*) > 3 UNION SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId INTERSECT SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId INTERSECT SELECT T1.Id , T1.FullName FROM car_makers AS T1 JOIN cars_data AS T2 ON T1.Id = T2.MakeId WHERE T2.Model = \" Fiat : 1800\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:179", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which State does Airways \"JetBlue Airways\" belong to?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airports AS T1 JOIN airlines AS T2 ON T1.AirportCode = T2.Airline WHERE T2.Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:180", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What State is Jetblue Airways affiliated with?", + "gold_sql": "SELECT Country FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT T1.State FROM airports AS T1 JOIN airlines AS T2 ON T1.AirportCode = T2.Airline WHERE T2.Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:181", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of Airline \"JetBlue Airways\"?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"JetBlue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:182", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which shortened word corresponds to Jetblue Airways?", + "gold_sql": "SELECT Abbreviation FROM AIRLINES WHERE Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT Abbreviation FROM airlines WHERE Airline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:183", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List all airway names and their shortened word in \"USA\".", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirportName , T1.Abbreviation FROM airports AS T1 JOIN airlines AS T2 ON T1.Abbreviation = T2.Abbreviation WHERE T2.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:184", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the airway names and shortened words for airways in the USA?", + "gold_sql": "SELECT Airline , Abbreviation FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT T1.AirwayName , T1.Abbreviation FROM airlines AS T1 JOIN airports AS T2 ON T1.AirportCode = T2.AirportCode WHERE T2.Country = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:185", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "List the airport code and name in the city of Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:186", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airport code and airport name corresonding to the city Anthony.", + "gold_sql": "SELECT AirportCode , AirportName FROM AIRPORTS WHERE city = \"Anthony\"", + "pred_sql": "SELECT AirportCode , AirportName FROM airports WHERE City = \"Anthony\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:187", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways do we have?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:188", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the total amount of airways?", + "gold_sql": "SELECT count(*) FROM AIRLINES", + "pred_sql": "SELECT sum(T1.Airway) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:189", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many aerodromes do we have?", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:190", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of aerodromes.", + "gold_sql": "SELECT count(*) FROM AIRPORTS", + "pred_sql": "SELECT count(*) FROM airports WHERE type = 'Airport';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:191", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights do we have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:192", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS", + "pred_sql": "SELECT count(*) FROM flights", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:193", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway can be shortened as word 'UAL'?", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.Airway FROM airlines AS T1 JOIN airports AS T2 ON T1.Abbreviation = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:194", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the airway with abbreviation 'UAL'.", + "gold_sql": "SELECT Airline FROM AIRLINES WHERE Abbreviation = \"UAL\"", + "pred_sql": "SELECT T1.AirportCode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.airline = 'UAL'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:195", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many airways are from USA?", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airlines JOIN airports ON airlines.country = 'USA' WHERE airlines.abbreviation = 'US Airline'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:196", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of airways in the USA.", + "gold_sql": "SELECT count(*) FROM AIRLINES WHERE Country = \"USA\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN airlines AS T2 ON T1.country = T2.country WHERE T2.Abbreviation = \"Airway\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:197", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town and State is the Alton airport at?", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT T1.AirportName , T1.Country FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport WHERE T2.FlightNo = 101 AND T1.City = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:198", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the town and State for the Alton airport.", + "gold_sql": "SELECT City , Country FROM AIRPORTS WHERE AirportName = \"Alton\"", + "pred_sql": "SELECT City , CountryAbbrev FROM airports WHERE AirportName = \"Alton\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:199", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome name for airport 'AKO'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:200", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the name of the aerodrome with code 'AKO'.", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE AirportCode = \"AKO\"", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode = \"AKO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:201", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are aerodrome names at town 'Aberdeen'?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:202", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are the names of aerodrome in Aberdeen?", + "gold_sql": "SELECT AirportName FROM AIRPORTS WHERE City = \"Aberdeen\"", + "pred_sql": "SELECT AirportName FROM airports WHERE City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:203", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from 'APG'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:204", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the amount of flights departing from 'APG'.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:205", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights have terminal ATO?", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATOL\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:206", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of flights into ATO.", + "gold_sql": "SELECT count(*) FROM FLIGHTS WHERE DestAirport = \"ATO\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.airportname = \"ATO\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:207", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City Aberdeen?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceAirport = T2.airportCode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:208", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights departing from Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:209", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights arriving in Aberdeen city?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:210", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of flights arriving in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:211", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights depart from City 'Aberdeen' and have destination City 'Ashley'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 'AA' AND T1.flightno = 'K123'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:212", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights fly from Aberdeen to Ashley?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRPORTS AS T3 ON T1.SourceAirport = T3.AirportCode WHERE T2.City = \"Ashley\" AND T3.City = \"Aberdeen\"", + "pred_sql": "SELECT count(*) FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.city = \"Aberdeen\" AND T1.airportname = \"Ashley\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:213", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights does airway 'JetBlue Airways' have?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM airlines AS T1 JOIN flights AS T2 ON T1.uid = T2.airline WHERE T1.Airline = 'JetBlue Airways'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:214", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the number of Jetblue Airways flights.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T1.Airline = T2.uid WHERE T2.Airline = \"JetBlue Airways\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.abbreviation WHERE T2.Aline = \"Jetblue Airways\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:215", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights go to Airport 'ASY'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airlinename = 'United Airlines' AND T2.airportname = 'ASY'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:216", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights arriving in ASY Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.DestAirport = \"ASY\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = 'ASY Airport' AND T1.Airline = 'United Airlines'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:217", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many 'United Airlines' flights leave from Airport 'AHD'?", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.sourceairport = T2.airportcode WHERE T2.airportname = \"AHD\" AND T1.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:218", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Return the number of United Airlines flights leaving from AHD Airport.", + "gold_sql": "SELECT count(*) FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T2.Airline = T1.uid WHERE T1.Airline = \"United Airlines\" AND T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.AirportName = \"AHD\" AND T1.Airline = \"United\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:219", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many United Airlines flights go to City 'Aberdeen'?", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode WHERE T2.city = 'Aberdeen' AND T1.airline = 'United'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:220", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Count the number of United Airlines flights that arrive in Aberdeen.", + "gold_sql": "SELECT count(*) FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode JOIN AIRLINES AS T3 ON T3.uid = T1.Airline WHERE T2.City = \"Aberdeen\" AND T3.Airline = \"United Airlines\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode JOIN airlines AS T3 ON T3.Ui = T1.airline WHERE T3.Abbreviation = \"United\" AND T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:221", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of arriving flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:222", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has the most frequent terminal aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT city FROM airports WHERE airportcode IN (SELECT airportcode FROM flights GROUP BY airportcode ORDER BY count(*) DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:223", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town has most number of departing flights?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.AirportName FROM airports AS T1 JOIN flights AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:224", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which town is the most frequent source aerodrome?", + "gold_sql": "SELECT T1.City FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.SourceAirport GROUP BY T1.City ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.city FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.city ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:225", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has the highest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:226", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the aerodrome code of the aerodrome with the most flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T2.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:227", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the code of aerodrome that has fewest number of flights?", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.airportcode FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T2.airportcode ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:228", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the code of the aerodrome with the least flights.", + "gold_sql": "SELECT T1.AirportCode FROM AIRPORTS AS T1 JOIN FLIGHTS AS T2 ON T1.AirportCode = T2.DestAirport OR T1.AirportCode = T2.SourceAirport GROUP BY T1.AirportCode ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.AirportCode FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T2.AirportCode ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:229", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airway has most number of flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.airportname FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport GROUP BY T1.airportcode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:230", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What airway serves the most flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Airway FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T2.Airway ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:231", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the shortened word and State of the airway that has fewest number of flights?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.ShortenedWord , T1.StateOfTheAireway FROM flights AS T1 JOIN (SELECT ShortenedWord , StateOfTheAireway FROM airports) AS T2 ON T1.DestAirport = T2.AirportCode GROUP BY T1.StateOfTheAireway ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:232", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What is the shortened word of the airway has the fewest flights and what State is it in?", + "gold_sql": "SELECT T1.Abbreviation , T1.Country FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline ORDER BY count(*) LIMIT 1", + "pred_sql": "SELECT T2.Abbreviation , T1.FlightNo FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.uid GROUP BY T1.airline ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:233", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have some flight departing from aerodrome 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:234", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with source airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"AHD\"", + "pred_sql": "SELECT T2.Airway FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T1.SourceAirport = \"AHD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:235", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are airways that have flights arriving at airport 'AHD'?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:236", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have a flight with terminal airport AHD?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.DestAirport = \"AHD\"", + "pred_sql": "SELECT T1.airway FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T2.destairport = 'AHD'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:237", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from both aerodromes 'APG' and 'CVO'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN flights AS T3 ON T2.FlightNo = T3.FlightNo WHERE T1.airportname = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport JOIN flights AS T3 ON T2.FlightNo = T3.FlightNo WHERE T1.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:238", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departing flights from both APG and CVO aerodromes?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\" INTERSECT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'APG' INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport INTERSECT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.destairport WHERE T1.airportname = 'CVO'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:239", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have flights from airport 'CVO' but not from 'APG'.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'CVO' EXCEPT SELECT T1.airportcode FROM airports AS T1 JOIN flights AS T2 ON T1.airportcode = T2.sourceairport WHERE T1.airportname = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:240", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have departures from CVO but not from APG airports?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"CVO\" EXCEPT SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline WHERE T2.SourceAirport = \"APG\"", + "pred_sql": "SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.airline WHERE T2.sourceairport = 'CVO' EXCEPT SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.airline WHERE T2.sourceairport = 'APG'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:241", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have at least 10 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airline FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:242", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have at least 10 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) > 10", + "pred_sql": "SELECT T1.airline FROM flights AS T1 JOIN airports AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.airline HAVING count(*) >= 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:243", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find all airways that have fewer than 200 flights.", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.airline FROM flights AS T1 JOIN (airports) AS T2 ON T1.destairport = T2.airportcode GROUP BY T1.airline HAVING count(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:244", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which airways have less than 200 flights?", + "gold_sql": "SELECT T1.Airline FROM AIRLINES AS T1 JOIN FLIGHTS AS T2 ON T1.uid = T2.Airline GROUP BY T1.Airline HAVING count(*) < 200", + "pred_sql": "SELECT T1.Airway FROM airlines AS T1 JOIN flights AS T2 ON T1.UID = T2.SourceAirport GROUP BY T1.Airway HAVING COUNT(*) < 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:245", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of airway \"United Airlines\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT T1.Airline , T1.FLIGHTNO FROM airlines AS T1 JOIN flights AS T2 ON T1.Ui = T2.SourceAirport WHERE T1.Abbreviation = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:246", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which flight codes correspond to United Airlines flights?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRLINES AS T2 ON T2.uid = T1.Airline WHERE T2.Airline = \"United Airlines\"", + "pred_sql": "SELECT DISTINCT flightno FROM flights AS T1 JOIN airlines AS T2 ON T1.airline = T2.abbreviation WHERE T2.airline = \"United Airlines\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:247", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:248", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE SourceAirport = \"APG\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE SourceAirport = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:249", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving at Airport \"APG\"?", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:250", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights landing at APG.", + "gold_sql": "SELECT FlightNo FROM FLIGHTS WHERE DestAirport = \"APG\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.AirportName = \"APG\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:251", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights departing from City \"Aberdeen \"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen \"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:252", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights leaving from Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.SourceAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT FlightNo FROM flights WHERE sourceairport = 'Aberdeen'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:253", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "What are flight codes of flights arriving in City \"Aberdeen\"?", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:254", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Give the flight codes of flights arriving in Aberdeen.", + "gold_sql": "SELECT T1.FlightNo FROM FLIGHTS AS T1 JOIN AIRPORTS AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:255", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the code of flights landing in the city of Aberdeen or Abilene.", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT T1.FlightNo FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:256", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "How many flights land in Aberdeen or Abilene?", + "gold_sql": "SELECT count(*) FROM Flights AS T1 JOIN Airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.city = \"Aberdeen\" OR T2.city = \"Abilene\"", + "pred_sql": "SELECT count(*) FROM flights AS T1 JOIN airports AS T2 ON T1.DestAirport = T2.AirportCode WHERE T2.City = \"Aberdeen\" OR T2.City = \"Abilene\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:257", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Find the name of aerodromes which do not have any flight in and out.", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport , sourceairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:258", + "benchmark": "spider_syn", + "split": "test", + "db_id": "flight_2", + "question": "Which aerodromes do not have leaving or arriving flights?", + "gold_sql": "SELECT AirportName FROM Airports WHERE AirportCode NOT IN (SELECT SourceAirport FROM Flights UNION SELECT DestAirport FROM Flights)", + "pred_sql": "SELECT airportname FROM airports WHERE airportcode NOT IN (SELECT destairport FROM flights UNION SELECT srcairport FROM flights)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:259", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many workers are there?", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:260", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs", + "gold_sql": "SELECT count(*) FROM employee", + "pred_sql": "SELECT count(*) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:261", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort worker names by their age in ascending order.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:262", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "List the names of workers and sort in ascending order of age.", + "gold_sql": "SELECT name FROM employee ORDER BY age", + "pred_sql": "SELECT name FROM employee ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:263", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the number of workers from each town?", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:264", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of staffs for each town.", + "gold_sql": "SELECT count(*) , city FROM employee GROUP BY city", + "pred_sql": "SELECT count(*) , district FROM shop GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:265", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which towns do more than one staff under age 30 come from?", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT DISTINCT T1.city FROM employee AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 INTERSECT SELECT DISTINCT T1.city FROM employee AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T2.age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:266", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the towns that have more than one worker under age 30.", + "gold_sql": "SELECT city FROM employee WHERE age < 30 GROUP BY city HAVING count(*) > 1", + "pred_sql": "SELECT T1.city FROM employee AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id WHERE T1.age < 30 GROUP BY T1.city HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:267", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of shops in each city.", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:268", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many stores are there in each city?", + "gold_sql": "SELECT count(*) , LOCATION FROM shop GROUP BY LOCATION", + "pred_sql": "SELECT count(*) , city FROM shop GROUP BY city", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:269", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the head name and district of the shop whose number of commodities is the largest.", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:270", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the director name and district of the market that sells the largest number of goods?", + "gold_sql": "SELECT manager_name , district FROM shop ORDER BY number_products DESC LIMIT 1", + "pred_sql": "SELECT manager_name , district FROM shop GROUP BY district ORDER BY sum(number_products) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:271", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the minimum and maximum number of merchandises of all stores.", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:272", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the minimum and maximum number of goods across all the stores?", + "gold_sql": "SELECT min(Number_products) , max(Number_products) FROM shop", + "pred_sql": "SELECT min(number_products) , max(number_products) FROM shop", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:273", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Return the name, city and district of all markets in descending order of number of commodities.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district FROM shop GROUP BY name , district ORDER BY count(*) DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:274", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Sort all the stores by number merchandises in descending order, and return the name, city and district of each store.", + "gold_sql": "SELECT name , LOCATION , district FROM shop ORDER BY number_products DESC", + "pred_sql": "SELECT name , district , location FROM shop ORDER BY number_products DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:275", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of stores whose number merchandises is more than the average number of merchandises.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:276", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shops' number goods is above the average? Give me the store names.", + "gold_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "pred_sql": "SELECT name FROM shop WHERE number_products > (SELECT avg(number_products) FROM shop)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:277", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "find the name of staff who was awarded the most times in the assessment.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T2.employee_id ORDER BY bonus DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:278", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the most awards in assessments? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID GROUP BY t2.Employee_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id GROUP BY T1.employee_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:279", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the worker who got the highest one time premium.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN hiring AS T2 ON T1.employee_id = T2.employee_id ORDER BY T2.is_full_time DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:280", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which worker received the biggest extra prize? Give me the worker name.", + "gold_sql": "SELECT t1.name FROM employee AS t1 JOIN evaluation AS t2 ON t1.Employee_ID = t2.Employee_ID ORDER BY t2.bonus DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id WHERE bonus = (SELECT max(bonus) FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:281", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the names of staffs who never won any award in the assessment.", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee WHERE employee_id NOT IN (SELECT employee_id FROM evaluation)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:282", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What are the names of the staffs who never received any assessment?", + "gold_sql": "SELECT name FROM employee WHERE Employee_ID NOT IN (SELECT Employee_ID FROM evaluation)", + "pred_sql": "SELECT name FROM employee EXCEPT SELECT T1.name FROM employee AS T1 JOIN evaluation AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:283", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is the name of the store that is hiring the largest number of workers?", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.name FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id WHERE T1.is_full_time = 'Y' GROUP BY T2.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:284", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which shop has the most workers? Give me the store name.", + "gold_sql": "SELECT t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t1.shop_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT name FROM shop ORDER BY manager_name DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:285", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the name of the stores that do not hire any people.", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:286", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which stores run with no workers? Find the store names", + "gold_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "pred_sql": "SELECT name FROM shop WHERE shop_id NOT IN (SELECT shop_id FROM hiring)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:287", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the number of staffs hired in each store; show the store name as well.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T2.manager_name , count(*) FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:288", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "For each store, return the number of people working there and the name of the store.", + "gold_sql": "SELECT count(*) , t2.name FROM hiring AS t1 JOIN shop AS t2 ON t1.shop_id = t2.shop_id GROUP BY t2.name", + "pred_sql": "SELECT T2.manager_name , count(*) FROM hiring AS T1 JOIN shop AS T2 ON T1.shop_id = T2.shop_id GROUP BY T1.shop_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:289", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is total premium given in all assessments?", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T1.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.employee_id = T2.employee_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:290", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the total amount of extra prize given in all the assessments.", + "gold_sql": "SELECT sum(bonus) FROM evaluation", + "pred_sql": "SELECT sum(T2.Bonus) FROM evaluation AS T1 JOIN employee AS T2 ON T1.Employee_ID = T2.Employee_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:291", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Give me all the information about hiring.", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:292", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "What is all the information about hiring?", + "gold_sql": "SELECT * FROM hiring", + "pred_sql": "SELECT * FROM hiring", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:293", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Which district has both stores with less than 3000 goods and stores with more than 10000 goods?", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:294", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Find the districts in which there are both shops selling less than 3000 goods and markets selling more than 10000 goods.", + "gold_sql": "SELECT district FROM shop WHERE Number_products < 3000 INTERSECT SELECT district FROM shop WHERE Number_products > 10000", + "pred_sql": "SELECT district FROM shop WHERE number_products < 3000 INTERSECT SELECT district FROM shop WHERE number_products > 10000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:295", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "How many different store city are there?", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:296", + "benchmark": "spider_syn", + "split": "test", + "db_id": "employee_hire_evaluation", + "question": "Count the number of distinct store city.", + "gold_sql": "SELECT count(DISTINCT LOCATION) FROM shop", + "pred_sql": "SELECT count(DISTINCT city) FROM employee", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:297", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many papers do we have?", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Papers", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:298", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of papers.", + "gold_sql": "SELECT count(*) FROM Documents", + "pred_sql": "SELECT count(*) FROM Ref_Template_types UNION SELECT count(*) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:299", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List paper IDs, paper names, and paper descriptions for all papers.", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text , T3.template_details FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:300", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, names, and descriptions for all papers?", + "gold_sql": "SELECT document_id , document_name , document_description FROM Documents", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:301", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the document name and layout id for document with description with the letter 'w' in it?", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT document_name , layout_id FROM documents WHERE document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:302", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the names and layout ids for papers that contain the letter w in their describing content.", + "gold_sql": "SELECT document_name , template_id FROM Documents WHERE Document_Description LIKE \"%w%\"", + "pred_sql": "SELECT T1.document_id , T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_description LIKE '%w%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:303", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id, layout id and describing content for paper named \"Robbin CV\"?", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.paper_id , t2.layout_id , t1.template_details FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:304", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the paper id, layout id, and describing details for the paper with the name Robbin CV.", + "gold_sql": "SELECT document_id , template_id , Document_Description FROM Documents WHERE document_name = \"Robbin CV\"", + "pred_sql": "SELECT t1.paper_id , t1.layout_id , t2.paragraph_text FROM Documents AS t1 JOIN Paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.document_name = \"Robbin CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:305", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many different layout do all document use?", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:306", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of different layout used for text files.", + "gold_sql": "SELECT count(DISTINCT template_id) FROM Documents", + "pred_sql": "SELECT count(DISTINCT layout) FROM documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:307", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many text files are using the layout with type code 'PPT'?", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id JOIN Templates AS T3 ON T2.template_id = T3.template_id WHERE T3.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:308", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of text files that use the PPT template type.", + "gold_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.Template_ID = T2.Template_ID WHERE T2.Template_Type_Code = 'PPT'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id WHERE T2.template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:309", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout ids and number of text files using each layout.", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:310", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are all different layout ids used for papers, and how many times were each of them used?", + "gold_sql": "SELECT template_id , count(*) FROM Documents GROUP BY template_id", + "pred_sql": "SELECT layout_id , count(*) FROM Documents GROUP BY layout_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:311", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the id and type for the layout used by the most papers?", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:312", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and type of the layout that is used for the greatest number of papers.", + "gold_sql": "SELECT T1.template_id , T2.Template_Type_Code FROM Documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_id , t1.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:313", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all layouts that are used by more than one text file.", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:314", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the template ids of any templates used in more than a single paper?", + "gold_sql": "SELECT template_id FROM Documents GROUP BY template_id HAVING count(*) > 1", + "pred_sql": "SELECT T1.template_id FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:315", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show ids for all templates not used by any text file.", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM Templates EXCEPT SELECT T1.template_id FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:316", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids for layout that are not used in any papers?", + "gold_sql": "SELECT template_id FROM Templates EXCEPT SELECT template_id FROM Documents", + "pred_sql": "SELECT template_id FROM layouts EXCEPT SELECT DISTINCT template_id FROM papers", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:317", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout do we have?", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM ...", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:318", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout.", + "gold_sql": "SELECT count(*) FROM Templates", + "pred_sql": "SELECT count(*) FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:319", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show layout ids, version numbers, and layout type for all layout.", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT layout_id , version_number , layout_type FROM layouts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:320", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids, edition numbers, and type name for each layout?", + "gold_sql": "SELECT template_id , version_number , template_type_code FROM Templates", + "pred_sql": "SELECT T1.template_id , T2.version_number , T3.template_type_description FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code JOIN Template_Preferences AS T3 ON T1.template_id = T3.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:321", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all distinct layout type names for all layout.", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT layout FROM layout", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:322", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type names?", + "gold_sql": "SELECT DISTINCT template_type_code FROM Templates", + "pred_sql": "SELECT DISTINCT t2.template_type_description FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:323", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of layout with layout type code PP or PPT?", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:324", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids of layout that have the code PP or PPT.", + "gold_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "pred_sql": "SELECT template_id FROM Templates WHERE template_type_code = \"PP\" OR template_type_code = \"PPT\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:325", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many layout have template type code CV?", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:326", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of layout of the type CV.", + "gold_sql": "SELECT count(*) FROM Templates WHERE template_type_code = \"CV\"", + "pred_sql": "SELECT count(*) FROM templates WHERE template_type_code = \"CV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:327", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the edition number and layout type for the layout with edition number later than 5?", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT edition_number , layout_type FROM Templates WHERE edition_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:328", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the edition numbers and layout type names of layout with a edition number greater than 5.", + "gold_sql": "SELECT version_number , template_type_code FROM Templates WHERE version_number > 5", + "pred_sql": "SELECT T1.edition_number , T2.layout_type_name FROM Templates AS T1 JOIN Layouts AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.version_number > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:329", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type codes and number of layout for each.", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:330", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout type, and how many layout correspond to each?", + "gold_sql": "SELECT template_type_code , count(*) FROM Templates GROUP BY template_type_code", + "pred_sql": "SELECT count(*) , layout_type FROM templates GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:331", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type code has most number of layout?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:332", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type name of the layout type that the most layout belong to.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:333", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types with less than three layouts.", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types GROUP BY template_type_description HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:334", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that have fewer than 3 layouts?", + "gold_sql": "SELECT template_type_code FROM Templates GROUP BY template_type_code HAVING count(*) < 3", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code GROUP BY t1.template_type_code HAVING count(*) < 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:335", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What the smallest edition number and its layout type code?", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , min(Template_Type_Code) FROM Templates", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:336", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the lowest edition number, along with its corresponding layout type code.", + "gold_sql": "SELECT min(Version_Number) , template_type_code FROM Templates", + "pred_sql": "SELECT min(Version_Number) , Template_Type_Code FROM Templates GROUP BY Template_Type_Code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:337", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type code of the layout used by layout with the name \"Data base\"?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM Templates AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_details = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:338", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type code of the layout that is used by a text file named Data base.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T2.document_name = \"Data base\"", + "pred_sql": "SELECT t1.template_type_code FROM templates AS t1 JOIN Documents AS t2 ON t1.template_id = t2.template_id WHERE t2.Other_details = \"Data base\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:339", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file names using layout with layout type code BK.", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT DISTINCT t1.document_name FROM documents AS t1 JOIN templates AS t2 ON t1.template_id = t2.template_id WHERE t2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:340", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of papers that use layouts with the code BK?", + "gold_sql": "SELECT T2.document_name FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id WHERE T1.template_type_code = \"BK\"", + "pred_sql": "SELECT T3.document_name FROM documents AS T1 JOIN Templates AS T2 ON T1.template_id = T2.template_id JOIN paragraphs AS T3 ON T1.paragraph_id = T3.paragraph_id WHERE T2.template_type_code = \"BK\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:341", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and the number of papers using each type.", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT T1.template_type_description , count(*) FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code GROUP BY T1.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:342", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the different layout types, and how many papers use each type?", + "gold_sql": "SELECT T1.template_type_code , count(*) FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code", + "pred_sql": "SELECT count(*) , layout_type FROM Ref_layouts GROUP BY layout_type", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:343", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Which layout type is used by most number of text files?", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Paragraphs AS t2 ON t1.template_type_code = t2.document_template_id GROUP BY t1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:344", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the code of the layout type that is most commonly used in text files.", + "gold_sql": "SELECT T1.template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id GROUP BY T1.template_type_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT template_type_code FROM templates GROUP BY template_type_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:345", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout types that are not used by any text file.", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_code FROM Ref_Template_Types EXCEPT SELECT DISTINCT template_type_code FROM Documents", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:346", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the names of layout types that are not used for any text file?", + "gold_sql": "SELECT template_type_code FROM Templates EXCEPT SELECT template_type_code FROM Templates AS T1 JOIN Documents AS T2 ON T1.template_id = T2.template_id", + "pred_sql": "SELECT DISTINCT template_type_description FROM Ref_Template_Types EXCEPT SELECT DISTINCT t2.template_type_description FROM Paragraphs AS t1 JOIN Ref_Template_Types AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.paragraph_text = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:347", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all layout type names and describing details.", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T2.template_type_name , T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:348", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the type names and describing details for all layout types?", + "gold_sql": "SELECT template_type_code , template_type_description FROM Ref_template_types", + "pred_sql": "SELECT T1.template_type_description , T2.template_type_code FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:349", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type describing content for layout type code \"AD\".", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT T1.template_type_description FROM Ref_Template_Types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:350", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the layout type describing content of the layout type with the code AD.", + "gold_sql": "SELECT template_type_description FROM Ref_template_types WHERE template_type_code = \"AD\"", + "pred_sql": "SELECT t2.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = \"AD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:351", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the layout type name for layout type description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:352", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the type of the layout type with the description \"Book\".", + "gold_sql": "SELECT template_type_code FROM Ref_template_types WHERE template_type_description = \"Book\"", + "pred_sql": "SELECT t1.template_type_code FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code WHERE t1.template_type_description = \"Book\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:353", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the distinct layout type descriptions for the layouts ever used by any text file?", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Documents AS t2 ON t1.template_type_code = t2.template_type_code WHERE t2.document_name = \"text file\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:354", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different describing content for layouts that have been used in a text file.", + "gold_sql": "SELECT DISTINCT T1.template_type_description FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code JOIN Documents AS T3 ON T2.Template_ID = T3.template_ID", + "pred_sql": "SELECT DISTINCT t1.template_type_description FROM Ref_Template_Types AS t1 JOIN Templates AS t2 ON t1.template_type_code = t2.template_type_code JOIN Documents AS t3 ON t2.template_id = t3.template_id WHERE t3.document_name = 'text_file'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:355", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the layout ids with layout type describing content \"Presentation\".", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT layout_id FROM Ref_Template_Types WHERE template_type_description = \"Presentation\" UNION SELECT layout_id FROM Templates WHERE template_type_code = \"Presentation\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:356", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the ids corresponding to layouts with the describing content 'Presentation'.", + "gold_sql": "SELECT T2.template_id FROM Ref_template_types AS T1 JOIN Templates AS T2 ON T1.template_type_code = T2.template_type_code WHERE T1.template_type_description = \"Presentation\"", + "pred_sql": "SELECT T1.template_id FROM Templates AS T1 JOIN Ref_Template_Types AS T2 ON T1.template_type_code = T2.template_type_code WHERE T2.template_type_description = 'Presentation'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:357", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs in total?", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:358", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs.", + "gold_sql": "SELECT count(*) FROM Paragraphs", + "pred_sql": "SELECT count(*) FROM paragraphs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:359", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "How many paragraphs for the text file with name 'Summer Show'?", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM documents AS t1 JOIN paragraphs AS t2 ON t1.document_id = t2.document_id WHERE t1.Other_Details = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:360", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Count the number of paragraphs in the text file named 'Summer Show'.", + "gold_sql": "SELECT count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_ID = T2.document_ID WHERE T2.document_name = 'Summer Show'", + "pred_sql": "SELECT count(*) FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.Other_Details = 'Summer Show'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:361", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show paragraph details for paragraph with text 'Korea'.", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:362", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the details for the paragraph that includes the text 'Korea'?", + "gold_sql": "SELECT Other_Details FROM Paragraphs WHERE paragraph_text = 'Korea'", + "pred_sql": "SELECT other_details FROM paragraphs WHERE paragraph_text LIKE '%Korea%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:363", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph ids and content for the text file with name 'Welcome to NY'.", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT T1.paragraph_id , T2.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Welcome to NY\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:364", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and content of paragraphs in the text file titled 'Welcome to NY'?", + "gold_sql": "SELECT T1.paragraph_id , T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.Document_Name = 'Welcome to NY'", + "pred_sql": "SELECT paragraph_id , paragraph_text FROM paragraphs WHERE document_id IN (SELECT document_id FROM documents WHERE document_name = 'Welcome to NY')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:365", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paragraph content for the text file \"Customer reviews\".", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT Paragraph_Text FROM Paragraphs WHERE document_id IN (SELECT document_id FROM Documents WHERE document_name = \"Customer reviews\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:366", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the paragraph content for the text file with the name 'Customer reviews'?", + "gold_sql": "SELECT T1.paragraph_text FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = \"Customer reviews\"", + "pred_sql": "SELECT T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id WHERE T1.document_name = \"Customer reviews\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:367", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all paper ids and the number of paragraphs in each text file. Order by paper id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:368", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the different paper ids along with the number of paragraphs corresponding to each, ordered by id.", + "gold_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY document_id", + "pred_sql": "SELECT document_id , count(*) FROM Paragraphs GROUP BY document_id ORDER BY count(*)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:369", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show all text file ids, names and the number of paragraphs in each paper.", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT count(*) , T1.document_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:370", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids and names of each paper, as well as the number of paragraphs in each?", + "gold_sql": "SELECT T1.document_id , T2.document_name , count(*) FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id", + "pred_sql": "SELECT count(*) , T1.template_id , T2.paragraph_text FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:371", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "List all name ids with at least two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:372", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that have 2 or more paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) >= 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:373", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the text file id and name with greatest number of paragraphs?", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T2.document_name FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:374", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id and name of the paper with the most paragraphs.", + "gold_sql": "SELECT T1.document_id , T2.document_name FROM Paragraphs AS T1 JOIN Documents AS T2 ON T1.document_id = T2.document_id GROUP BY T1.document_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.template_id , T1.template_details FROM Documents AS T1 JOIN Paragraphs AS T2 ON T1.document_id = T2.document_id GROUP BY T1.template_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:375", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with least number of paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:376", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Return the id of the paper with the fewest paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:377", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What is the paper id with 1 to 2 paragraphs?", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM paragraphs GROUP BY document_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:378", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Give the ids of text files that have between one and two paragraphs.", + "gold_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "pred_sql": "SELECT document_id FROM Paragraphs GROUP BY document_id HAVING count(*) BETWEEN 1 AND 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:379", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "Show the paper id with paragraph text 'Brazil' and 'Ireland'.", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM paragraphs WHERE paragraph_text = 'Brazil' OR paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:380", + "benchmark": "spider_syn", + "split": "test", + "db_id": "cre_Doc_Template_Mgt", + "question": "What are the ids of text files that contain the paragraph text 'Brazil' and 'Ireland'?", + "gold_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "pred_sql": "SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Brazil' INTERSECT SELECT document_id FROM Paragraphs WHERE paragraph_text = 'Ireland'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:381", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "How many instructors are there?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:382", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the total count of faculties?", + "gold_sql": "SELECT count(*) FROM teacher", + "pred_sql": "SELECT count(*) FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:383", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of faculties in ascending order of age.", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:384", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties ordered by ascending age?", + "gold_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "pred_sql": "SELECT Name FROM teacher ORDER BY Age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:385", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the age and birthplace of instructors?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:386", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the age and birthplace of every instructor?", + "gold_sql": "SELECT Age , Hometown FROM teacher", + "pred_sql": "SELECT Age , Hometown FROM teacher", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:387", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the name of faculties whose birthplace is not \"Little Lever Urban District\".", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:388", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties whose birthplace is not \"Little Lever Urban District\"?", + "gold_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "pred_sql": "SELECT Name FROM teacher WHERE Hometown != \"Little Lever Urban District\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:389", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of faculties aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:390", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors who are aged either 32 or 33?", + "gold_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "pred_sql": "SELECT Name FROM teacher WHERE Age = 32 OR Age = 33", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:391", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the birthplace of the youngest instructor?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:392", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Where is the youngest instructor from?", + "gold_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "pred_sql": "SELECT Hometown FROM teacher ORDER BY Age ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:393", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show different birthplace of instructors and the number of instructors from each birthplace.", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:394", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "For each birthplace, how many instructors are there?", + "gold_sql": "SELECT Hometown , COUNT(*) FROM teacher GROUP BY Hometown", + "pred_sql": "SELECT Hometown , count(*) FROM teacher GROUP BY Hometown", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:395", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the most common birthplace of instructors.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT DISTINCT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:396", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the most commmon birthplaces for faculties?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT DISTINCT Staring_Date FROM course GROUP BY Staring_Date ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:397", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the birthplaces shared by at least two faculties.", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:398", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the towns from which at least two instructors come from?", + "gold_sql": "SELECT Hometown FROM teacher GROUP BY Hometown HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T1.Hometown FROM teacher AS T1 JOIN course_arrange AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Hometown HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:399", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors and the curriculums they are arranged to teach.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Course_ID FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:400", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What is the name of each faculty and what curriculum they teach?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID", + "pred_sql": "SELECT T2.Name , T1.Grade FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:401", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the curriculums they are arranged to teach in ascending alphabetical order of the faculty's name.", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:402", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties and the curriculums they teach in ascending alphabetical order by the name of the faculty?", + "gold_sql": "SELECT T3.Name , T2.Course FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID ORDER BY T3.Name", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID ORDER BY T2.Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:403", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show the name of the faculty for the math curriculum.", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT T2.Name FROM course AS T1 JOIN teacher AS T2 ON T1.Course_ID = T2.Teacher_ID WHERE T1.Course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:404", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the people who teach math?", + "gold_sql": "SELECT T3.Name FROM course_arrange AS T1 JOIN course AS T2 ON T1.Course_ID = T2.Course_ID JOIN teacher AS T3 ON T1.Teacher_ID = T3.Teacher_ID WHERE T2.Course = \"Math\"", + "pred_sql": "SELECT name FROM teacher WHERE course = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:405", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of faculties and the number of curriculums they teach.", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:406", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors and how many curriculums do they teach?", + "gold_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "pred_sql": "SELECT T2.Name , COUNT(*) FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:407", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "Show names of instructors that teach at least two curriculums.", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:408", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the faculties who teach at least two curriculums?", + "gold_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T2.Name HAVING COUNT(*) >= 2", + "pred_sql": "SELECT T2.Name FROM course_arrange AS T1 JOIN teacher AS T2 ON T1.Teacher_ID = T2.Teacher_ID GROUP BY T1.Teacher_ID HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:409", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "List the names of instructors who have not been arranged to teach curriculums.", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:410", + "benchmark": "spider_syn", + "split": "test", + "db_id": "course_teach", + "question": "What are the names of the instructors whose curriculums have not been arranged?", + "gold_sql": "SELECT Name FROM teacher WHERE Teacher_id NOT IN (SELECT Teacher_id FROM course_arrange)", + "pred_sql": "SELECT Name FROM teacher WHERE Teacher_ID NOT IN (SELECT Teacher_ID FROM course_arrange)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:411", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many guests below age 30 are there?", + "gold_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "pred_sql": "SELECT count(*) FROM visitor WHERE age < 30", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:412", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the names of the guests whose membership level is higher than 4, and order the results by the level from high to low.", + "gold_sql": "SELECT name FROM visitor WHERE Level_of_membership > 4 ORDER BY Level_of_membership DESC", + "pred_sql": "SELECT name FROM visitor WHERE LEVEL_of_membership > 4 ORDER BY LEVEL_of_membership DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:413", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the average age of the guests whose membership level is not higher than 4?", + "gold_sql": "SELECT avg(age) FROM visitor WHERE Level_of_membership <= 4", + "pred_sql": "SELECT avg(age) FROM visitor WHERE LEVEL_of_membership <= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:414", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and membership level of the guests whose membership level is higher than 4, and sort by their age from old to young.", + "gold_sql": "SELECT name , Level_of_membership FROM visitor WHERE Level_of_membership > 4 ORDER BY age DESC", + "pred_sql": "SELECT name , LEVEL_OF_MEMBERSHIP FROM visitor WHERE LEVEL_OF_MEMBERSHIP > 4 ORDER BY age DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:415", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the id and name of the museum that has the most workers?", + "gold_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "pred_sql": "SELECT museum_id , name FROM museum ORDER BY num_of_staff DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:416", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the average number of worker working for the museums that were open before 2009.", + "gold_sql": "SELECT avg(num_of_staff) FROM museum WHERE open_year < 2009", + "pred_sql": "SELECT avg(Num_of_Staff) FROM museum WHERE Open_Year < 2009", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:417", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the opening year and worker number of the museum named Plaza Museum?", + "gold_sql": "SELECT Num_of_Staff , Open_Year FROM museum WHERE name = 'Plaza Museum'", + "pred_sql": "SELECT Open_Year , Num_of_Staff FROM museum WHERE Name = \"Plaza Museum\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:418", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the names of museums which have more worker than the minimum worker number of all museums opened after 2010.", + "gold_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "pred_sql": "SELECT name FROM museum WHERE num_of_staff > (SELECT min(num_of_staff) FROM museum WHERE open_year > 2010)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:419", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "find the id, name and age for guests who visited some museums more than once.", + "gold_sql": "SELECT t1.id , t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t1.id HAVING count(*) > 1", + "pred_sql": "SELECT T2.id , T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T1.museum_ID = T3.museum_ID GROUP BY T2.id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:420", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id, name and membership level of guests who have spent the largest amount of money in total in all museum tickets?", + "gold_sql": "SELECT t2.visitor_id , t1.name , t1.Level_of_membership FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id GROUP BY t2.visitor_id ORDER BY sum(t2.Total_spent) DESC LIMIT 1", + "pred_sql": "SELECT T2.id , T2.name , T2.level_of_membership FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id WHERE T1.total_spent = (SELECT max(total_spent) FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:421", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the id and name of the museum visited most times?", + "gold_sql": "SELECT t2.Museum_ID , t1.name FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID GROUP BY t2.Museum_ID ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.museum_id , T2.name FROM visit AS T1 JOIN museum AS T2 ON T1.museum_id = T2.museum_id GROUP BY T1.museum_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:422", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the museum that had no tourist yet?", + "gold_sql": "SELECT name FROM museum WHERE Museum_ID NOT IN (SELECT museum_id FROM visit)", + "pred_sql": "SELECT name FROM museum WHERE museum_id NOT IN (SELECT museum_id FROM visit)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:423", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the name and age of the tourist who bought the most tickets at once.", + "gold_sql": "SELECT t1.name , t1.age FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id ORDER BY t2.num_of_ticket DESC LIMIT 1", + "pred_sql": "SELECT T2.name , T2.age FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_ID = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:424", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What are the average and maximum number of tickets bought in all guests?", + "gold_sql": "SELECT avg(num_of_ticket) , max(num_of_ticket) FROM visit", + "pred_sql": "SELECT avg(Num_of_Ticket) , max(Num_of_Ticket) FROM visit WHERE visitor_ID NOT IN (SELECT ID FROM visitor WHERE LEVEL_of_membership = \"Guest\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:425", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the total ticket expense of the guests whose membership level is 1?", + "gold_sql": "SELECT sum(t2.Total_spent) FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id WHERE t1.Level_of_membership = 1", + "pred_sql": "SELECT sum(T2.Total_spent) FROM visitor AS T1 JOIN visit AS T2 ON T1.ID = T2.visitor_ID WHERE T1.Level_of_membership = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:426", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "What is the name of the tourist who visited both a museum opened before 2009 and a museum opened after 2011?", + "gold_sql": "SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year < 2009 INTERSECT SELECT t1.name FROM visitor AS t1 JOIN visit AS t2 ON t1.id = t2.visitor_id JOIN museum AS t3 ON t3.Museum_ID = t2.Museum_ID WHERE t3.open_year > 2011", + "pred_sql": "SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T3.Museum_ID = T1.Museum_ID WHERE T3.open_year < 2009 INTERSECT SELECT T2.name FROM visit AS T1 JOIN visitor AS T2 ON T1.visitor_id = T2.id JOIN museum AS T3 ON T3.Museum_ID = T1.Museum_ID WHERE T3.open_year > 2011", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:427", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "Find the number of guests who did not visit any museum opened after 2010.", + "gold_sql": "SELECT count(*) FROM visitor WHERE id NOT IN (SELECT t2.visitor_id FROM museum AS t1 JOIN visit AS t2 ON t1.Museum_ID = t2.Museum_ID WHERE t1.open_year > 2010)", + "pred_sql": "SELECT count(*) FROM visitor WHERE id NOT IN ( SELECT visitor_id FROM visit WHERE museum_id AND open_year > 2010 )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:428", + "benchmark": "spider_syn", + "split": "test", + "db_id": "museum_visit", + "question": "How many museums were opened after 2013 or before 2008?", + "gold_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "pred_sql": "SELECT count(*) FROM museum WHERE open_year > 2013 OR open_year < 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:429", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of participants.", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:430", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there?", + "gold_sql": "SELECT count(*) FROM players", + "pred_sql": "SELECT count(*) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:431", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_level = \"T1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:432", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Count the number of competitions.", + "gold_sql": "SELECT count(*) FROM matches", + "pred_sql": "SELECT count(*) FROM matches WHERE tourney_level = \"T1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:433", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given name and birth date of all participants from the country with code USA.", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:434", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and birth dates of participants from the USA?", + "gold_sql": "SELECT first_name , birth_date FROM players WHERE country_code = 'USA'", + "pred_sql": "SELECT first_name , birth_date FROM players WHERE country_code = \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:435", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average age of losers and winners of all games.", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:436", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the average ages of losers and winners across games?", + "gold_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "pred_sql": "SELECT avg(loser_age) , avg(winner_age) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:437", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average rank of winners in all games.", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:438", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the average rank for winners in all competitions?", + "gold_sql": "SELECT avg(winner_rank) FROM matches", + "pred_sql": "SELECT avg(winner_rank) FROM matches WHERE winner_age >= 15", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:439", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the highest rank of losers in all competitions.", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:440", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the best rank of losers across all contest?", + "gold_sql": "SELECT min(loser_rank) FROM matches", + "pred_sql": "SELECT loser_rank FROM matches GROUP BY loser_rank ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:441", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of distinct State codes of all participants.", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT state_code) FROM participants", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:442", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many distinct States do participants come from?", + "gold_sql": "SELECT count(DISTINCT country_code) FROM players", + "pred_sql": "SELECT count(DISTINCT country_code) FROM players", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:443", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of distinct name of losers.", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:444", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different loser names are there?", + "gold_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "pred_sql": "SELECT count(DISTINCT loser_name) FROM matches", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:445", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the names of tourney that has more than 10 competitions.", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:446", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of tournaments that have more than 10 competitions?", + "gold_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "pred_sql": "SELECT tourney_name FROM matches GROUP BY tourney_name HAVING count(*) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:447", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the names of all winners who played in both 2013 and 2016.", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2013 INTERSECT SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T1.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:448", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of participants who won in both 2013 and 2016?", + "gold_sql": "SELECT winner_name FROM matches WHERE YEAR = 2013 INTERSECT SELECT winner_name FROM matches WHERE YEAR = 2016", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2013 INTERSECT SELECT T1.first_name , T1.last_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.year = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:449", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the number of all competitions who played in years of 2013 or 2016.", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:450", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many competitions were played in 2013 or 2016?", + "gold_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "pred_sql": "SELECT count(*) FROM matches WHERE YEAR = 2013 OR YEAR = 2016", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:451", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the nation code and given name of the participants who won in both tourney WTA Championships and Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"WTA Championships\" INTERSECT SELECT T1.country_code , T2.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = \"Australian Open\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:452", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names and State codes for participants who won both the WTA Championships and the Australian Open?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'WTA Championships' INTERSECT SELECT T1.first_name , T1.last_name , T2.state_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id WHERE T2.tourney_name = 'Australian Open'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:453", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and State abbreviation of the oldest participant.", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id ORDER BY T2.minutes LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:454", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and nation abbreviation of the oldest participant?", + "gold_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date LIMIT 1", + "pred_sql": "SELECT first_name , country_code FROM players ORDER BY birth_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:455", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:456", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all participants, sorted by birth date?", + "gold_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:457", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "List the given and family name of all participants who are left / L hand in the order of birth date.", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = \"left\" ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:458", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the full names of all left handed participants, in order of birth date?", + "gold_sql": "SELECT first_name , last_name FROM players WHERE hand = 'L' ORDER BY birth_date", + "pred_sql": "SELECT first_name , last_name FROM players WHERE hand = 'left' ORDER BY birth_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:459", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name and nation abbreviation of the participant who did the most number of tours.", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T1.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:460", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name and State code of the participant with the most tours?", + "gold_sql": "SELECT T1.country_code , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id ORDER BY T2.tours DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.tournament_level FROM rankings AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_id GROUP BY T2.loser_id ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:461", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the year that has the most number of competitions.", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:462", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Which year had the most competitions?", + "gold_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT YEAR FROM matches GROUP BY YEAR ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:463", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank points of the winner who won the most times.", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id GROUP BY T1.winner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:464", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner who has won the most matches, and how many rank points does this player have?", + "gold_sql": "SELECT winner_name , winner_rank_points FROM matches GROUP BY winner_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank_points FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id GROUP BY T2.player_id ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:465", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name of the winner who has the highest rank points and participated in the Australian Open tourney.", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id JOIN matches AS T3 ON T3.winner_id = T2.player_id WHERE T3.tourney_name = \"Australian Open\" ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:466", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the name of the winner with the most rank points who participated in the Australian Open tournament?", + "gold_sql": "SELECT winner_name FROM matches WHERE tourney_name = 'Australian Open' ORDER BY winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id JOIN tournaments AS T3 ON T1.tourney_id = T3.tourney_id WHERE T3.tournament_name = \"Australian Open\" ORDER BY T1.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:467", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the names of loser and winner who played in the competition with greatest number of minutes.", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.loser_name , T1.winner_name FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T1.loser_name ORDER BY avg(T1.minutes) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:468", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names of the winner and loser who played in the longest competition?", + "gold_sql": "SELECT winner_name , loser_name FROM matches ORDER BY minutes DESC LIMIT 1", + "pred_sql": "SELECT T1.winner_name , T1.loser_name FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.minutes DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:469", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the average ranking for each participant and their given name.", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT avg(T1.ranking) , T2.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T2.first_name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:470", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their average rankings?", + "gold_sql": "SELECT avg(ranking) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , avg(T1.ranking) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:471", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total ranking points for each participant and their given name.", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.ranking_points , T1.first_name FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:472", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the given names of all participants, and their total ranking points?", + "gold_sql": "SELECT sum(ranking_points) , T1.first_name FROM players AS T1 JOIN rankings AS T2 ON T1.player_id = T2.player_id GROUP BY T1.first_name", + "pred_sql": "SELECT T2.first_name , T2.last_name , sum(T1.ranking_points) FROM rankings AS T1 JOIN players AS T2 ON T1.player_id = T2.player_id GROUP BY T1.player_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:473", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the number of participants for each State.", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT count(*) , state FROM matches GROUP BY state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:474", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are from each State?", + "gold_sql": "SELECT count(*) , country_code FROM players GROUP BY country_code", + "pred_sql": "SELECT country_code , count(*) FROM players GROUP BY country_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:475", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "find the abbreviation of the State where has the greatest number of participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.abbr FROM matches AS T1 JOIN players AS T2 ON T1.loser_id = T2.player_id GROUP BY T2.country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:476", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the abbreviation of the nation with the most participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:477", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the abbreviations of nations that have more than 50 participants.", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:478", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the abbreviations of nations with more than 50 participants?", + "gold_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "pred_sql": "SELECT country_code FROM players GROUP BY country_code HAVING count(*) > 50", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:479", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the total number of trips for each ranking time.", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:480", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many total travels were there for each ranking time?", + "gold_sql": "SELECT sum(tours) , ranking_date FROM rankings GROUP BY ranking_date", + "pred_sql": "SELECT ranking , count(*) FROM rankings GROUP BY ranking", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:481", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of games happened in each year.", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:482", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many games were played in each year?", + "gold_sql": "SELECT count(*) , YEAR FROM matches GROUP BY YEAR", + "pred_sql": "SELECT YEAR , count(*) FROM matches GROUP BY YEAR", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:483", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the name and rank of the 3 youngest winners across all competitions.", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:484", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What are the names and ranks of the three youngest winners across all games?", + "gold_sql": "SELECT DISTINCT winner_name , winner_rank FROM matches ORDER BY winner_age LIMIT 3", + "pred_sql": "SELECT T1.winner_name , T1.winner_rank FROM matches AS T1 JOIN rankings AS T2 ON T1.winner_id = T2.player_id ORDER BY T1.year LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:485", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many different winners both participated in the WTA Championships and were left handed?", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"left\" INTERSECT SELECT count(DISTINCT T1.winner_name) FROM matches AS T1 JOIN players AS T2 ON T1.winner_id = T2.player_id WHERE T2.hand = \"wta\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:486", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of left handed winners who participated in the WTA Championships.", + "gold_sql": "SELECT count(DISTINCT winner_name) FROM matches WHERE tourney_name = 'WTA Championships' AND winner_hand = 'L'", + "pred_sql": "SELECT count(*) FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.loser_hand WHERE T1.hand = \"left\" AND T2.tourney_name = \"WTA Championships\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:487", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the given name, nation abbreviation and birth date of the winner who has the highest rank points in all games.", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T2.winner_name , T1.country_code , T2.birth_date FROM rankings AS T1 JOIN players AS T2 ON T2.player_id = T1.player_id ORDER BY T1.ranking_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:488", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "What is the given name, nation abbreviation, and birth date of the participant with the most winner rank points across all competitions?", + "gold_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.country_code , T1.birth_date FROM players AS T1 JOIN matches AS T2 ON T1.player_id = T2.winner_id ORDER BY T2.winner_rank_points DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:489", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "Find the number of participants for each hand type.", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:490", + "benchmark": "spider_syn", + "split": "test", + "db_id": "wta_1", + "question": "How many participants are there for each hand type?", + "gold_sql": "SELECT count(*) , hand FROM players GROUP BY hand", + "pred_sql": "SELECT hand , count(*) FROM players GROUP BY hand", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:491", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many vessels ended up being 'Captured'?", + "gold_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "pred_sql": "SELECT count(*) FROM ship WHERE disposition_of_ship = 'Captured'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:492", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and tonnage ordered by in descending alphaetical order for the names.", + "gold_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "pred_sql": "SELECT name , tonnage FROM ship ORDER BY name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:493", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name, date and result of each battle.", + "gold_sql": "SELECT name , date FROM battle", + "pred_sql": "SELECT name , date , result FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:494", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is maximum and minimum death toll caused each time?", + "gold_sql": "SELECT max(killed) , min(killed) FROM death", + "pred_sql": "SELECT max(id) , min(id) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:495", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the average number of injuries caused each time?", + "gold_sql": "SELECT avg(injured) FROM death", + "pred_sql": "SELECT avg(injured) FROM death", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:496", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the death and hurt situations caused by the vessel with tonnage 't'?", + "gold_sql": "SELECT T1.killed , T1.injured FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id WHERE T2.tonnage = 't'", + "pred_sql": "SELECT T2.note , T1.id FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id WHERE T1.tonnage = 't'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:497", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the name and results of the battles when the bulgarian commander is not 'Boril'", + "gold_sql": "SELECT name , RESULT FROM battle WHERE bulgarian_commander != 'Boril'", + "pred_sql": "SELECT name , result FROM battle WHERE bulgarian_commander != 'Boril'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:498", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the different ids and names of the combat that lost any 'Brig' type vessels?", + "gold_sql": "SELECT DISTINCT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.ship_type = 'Brig'", + "pred_sql": "SELECT DISTINCT T1.id , T1.name FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.bulgarian_commander WHERE T1.ship_type = 'Brig'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:499", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the ids and names of the combat that led to more than 10 people dead in total.", + "gold_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle JOIN death AS T3 ON T2.id = T3.caused_by_ship_id GROUP BY T1.id HAVING sum(T3.killed) > 10", + "pred_sql": "SELECT T1.id , T1.name FROM battle AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id HAVING sum(T2.killed) > 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:500", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What is the vessel id and name that caused most total injuries?", + "gold_sql": "SELECT T2.id , T2.name FROM death AS T1 JOIN ship AS t2 ON T1.caused_by_ship_id = T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.id , T1.name FROM ship AS T1 JOIN death AS T2 ON T1.id = T2.caused_by_ship_id GROUP BY T1.id ORDER BY sum(T2.injured) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:501", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the distinct combat names which are between bulgarian commander 'Kaloyan' and latin commander 'Baldwin I'?", + "gold_sql": "SELECT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "pred_sql": "SELECT DISTINCT name FROM battle WHERE bulgarian_commander = 'Kaloyan' AND latin_commander = 'Baldwin I'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:502", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many different results are there for the combats?", + "gold_sql": "SELECT count(DISTINCT RESULT) FROM battle", + "pred_sql": "SELECT count(DISTINCT result) FROM battle", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:503", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "How many combats did not lose any vessel with tonnage '225'?", + "gold_sql": "SELECT count(*) FROM battle WHERE id NOT IN ( SELECT lost_in_battle FROM ship WHERE tonnage = '225' );", + "pred_sql": "SELECT count(*) FROM battle WHERE result = 'win' OR (SELECT id FROM ship WHERE tonnage = 225) = 0", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:504", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "List the name and date the combat that has lost the vessel named 'Lettice' and the vessel named 'HMS Atalanta'", + "gold_sql": "SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'Lettice' INTERSECT SELECT T1.name , T1.date FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.name = 'HMS Atalanta'", + "pred_sql": "SELECT T2.name , T2.date FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.lost_in_battle WHERE T1.name = 'Lettice' INTERSECT SELECT T2.name , T2.date FROM ship AS T1 JOIN battle AS T2 ON T1.id = T2.lost_in_battle WHERE T1.name = 'HMS Atalanta'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:505", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "Show names, results and bulgarian commanders of the combats with no vessels lost in the 'English Channel'.", + "gold_sql": "SELECT name , RESULT , bulgarian_commander FROM battle EXCEPT SELECT T1.name , T1.result , T1.bulgarian_commander FROM battle AS T1 JOIN ship AS T2 ON T1.id = T2.lost_in_battle WHERE T2.location = 'English Channel'", + "pred_sql": "SELECT name , result , bulgarian_commander FROM battle WHERE id NOT IN (SELECT id FROM ship WHERE LOCATION = 'English Channel')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:506", + "benchmark": "spider_syn", + "split": "test", + "db_id": "battle_death", + "question": "What are the remark of the death events which has substring 'East'?", + "gold_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "pred_sql": "SELECT note FROM death WHERE note LIKE '%East%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:507", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "what are all the addresses including line 1 and line 2?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT address_id FROM Addresses WHERE line_1 = \"include\" AND line_2 = \"line1\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:508", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the first and second line for all addresses?", + "gold_sql": "SELECT line_1 , line_2 FROM addresses", + "pred_sql": "SELECT line_1 , line_2 FROM Addresses;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:509", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums in total are listed?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:510", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many curriculums are there?", + "gold_sql": "SELECT count(*) FROM Courses", + "pred_sql": "SELECT count(*) FROM Courses", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:511", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How is the math curriculum described?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT course_description FROM Courses WHERE course_name = \"Math\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:512", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the describing content for all the math curriculums?", + "gold_sql": "SELECT course_description FROM Courses WHERE course_name = 'math'", + "pred_sql": "SELECT DISTINCT T1.course_description FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id JOIN Departments AS T3 ON T2.section_id = T3.section_id WHERE T3.department_name = 'Math'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:513", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code of the position in the city Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE city = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:514", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the zip code for Port Chelsea?", + "gold_sql": "SELECT zip_postcode FROM Addresses WHERE city = 'Port Chelsea'", + "pred_sql": "SELECT zip_postcode FROM addresses WHERE line_1 = \"Port Chelsea\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:515", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which division offers the most number of degrees? List division name and id.", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T1.department_id FROM departments AS T1 JOIN degree_programs AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:516", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each division id, what is the name of the division with the most number of degrees?", + "gold_sql": "SELECT T2.department_name , T1.department_id FROM Degree_Programs AS T1 JOIN Departments AS T2 ON T1.department_id = T2.department_id GROUP BY T1.department_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.department_name , T2.department_id FROM departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id GROUP BY T2.department_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:517", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many departments offer any degree?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:518", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different departments offer degrees?", + "gold_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT department_id) FROM Degree_Programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:519", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degree names are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:520", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different degrees are offered?", + "gold_sql": "SELECT count(DISTINCT degree_summary_name) FROM Degree_Programs", + "pred_sql": "SELECT count(DISTINCT degree_summary_name) FROM degree_programs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:521", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering division offer?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:522", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many degrees does the engineering department have?", + "gold_sql": "SELECT count(*) FROM Departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'engineer'", + "pred_sql": "SELECT count(*) FROM departments AS T1 JOIN Degree_Programs AS T2 ON T1.department_id = T2.department_id WHERE T1.department_name = 'Engineering'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:523", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing contents of all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT section_name , section_description FROM Sections", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:524", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and describing details for all the sections?", + "gold_sql": "SELECT section_name , section_description FROM Sections", + "pred_sql": "SELECT T1.section_name , T1.section_description FROM Sections AS T1 JOIN Courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:525", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and id of curriculums having at most 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:526", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names and ids of every curriculum with less than 2 sections?", + "gold_sql": "SELECT T1.course_name , T1.course_id FROM Courses AS T1 JOIN Sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id HAVING count(*) <= 2", + "pred_sql": "SELECT T1.course_name , T1.section_id FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id GROUP BY T1.section_id HAVING count(*) < 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:527", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List the section_name in reversed lexicographical order.", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:528", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of the sections in reverse alphabetical order?", + "gold_sql": "SELECT section_name FROM Sections ORDER BY section_name DESC", + "pred_sql": "SELECT section_name FROM sections ORDER BY section_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:529", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the academic session which most undergraduate registered in? Show both the name and the id.", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.semester_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:530", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "For each semester, what is the name and id of the one with the most undergraduate registered?", + "gold_sql": "SELECT T1.semester_name , T1.semester_id FROM Semesters AS T1 JOIN Student_Enrolment AS T2 ON T1.semester_id = T2.semester_id GROUP BY T1.semester_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T3.semester_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN semesters AS T3 ON T2.semester_id = T3.semester_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:531", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the describing details of the division whose name has the substring the computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT department_description FROM DEPARTMENTS WHERE department_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:532", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the division describing details for the one whose name has the word computer?", + "gold_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "pred_sql": "SELECT department_description FROM Departments WHERE department_name LIKE '%computer%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:533", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who are enrolled in 2 degree programs in one term? List the given name, middle name and family name and the id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:534", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names, along with the ids, of all undergraduates who enrolled in 2 degree programs in one term?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id HAVING count(*) = 2", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id GROUP BY T1.student_id HAVING count(*) = 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:535", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is enrolled in a Bachelor degree program? List the given name, middle name, family name.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "{\"sql\": \"SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor\\'\"}", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:536", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given, middle, and family names for everybody enrolled in a Bachelors program?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id JOIN Degree_Programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id JOIN degree_programs AS T3 ON T2.degree_program_id = T3.degree_program_id WHERE T3.degree_summary_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:537", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the kind of program which most number of students are enrolled in?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , count(*) FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:538", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the degree summary name that has the most number of students enrolled?", + "gold_sql": "SELECT T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.degree_summary_name FROM Student_Enrolment AS T1 JOIN Degree_Programs AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T2.degree_summary_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:539", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the program which most number of students are enrolled in. List both the id and the summary.", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:540", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the program id and the summary of the degree that has the most students enrolled?", + "gold_sql": "SELECT T1.degree_program_id , T1.degree_summary_name FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.degree_program_id , T2.degree_summary_name FROM Degree_Programs AS T1 JOIN Students AS T2 ON T1.degree_program_id = T2.student_enrolment_id GROUP BY T1.degree_program_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:541", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which student has enrolled for the most times in any program? List the id, given name, middle name, family name, the number of enrollments and undergraduate id.", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.student_id , T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:542", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name, along with the id and number of enrollments, for the undergraduate who enrolled the most in any program?", + "gold_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , count(*) , T1.student_id FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name , T1.student_id , count(*) FROM Students AS T1 JOIN Student_Enrolment AS T2 ON T1.student_id = T2.student_id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:543", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which academic sessions do not have any student enrolled? List the academic session name.", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT session_name FROM semesters WHERE semester_id NOT IN (SELECT semester_id FROM student_enrolment)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:544", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the academic session with no students enrolled?", + "gold_sql": "SELECT semester_name FROM Semesters WHERE semester_id NOT IN( SELECT semester_id FROM Student_Enrolment )", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.inactive = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:545", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are all the course names of the curriculums which ever have students enrolled in?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN sections AS T2 ON T1.course_id = T2.course_id JOIN student_enrolment_courses AS T3 ON T2.course_id = T3.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:546", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the names of all curriculums that have some students enrolled?", + "gold_sql": "SELECT DISTINCT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:547", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What's the name of the curriculum with most number of enrollments?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:548", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the name of the curriculum with the most students enrolled?", + "gold_sql": "SELECT T1.course_name FROM Courses AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.course_name FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:549", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the family name of the students who currently live in the state of North Carolina but have not registered in any degree program.", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id JOIN student_enrolment_courses AS T3 ON T3.student_course_id = T2.student_course_id JOIN degree_programs AS T4 ON T4.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:550", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the family name of the students who live in North Carolina but have not registered in any degree programs?", + "gold_sql": "SELECT T1.last_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T2.state_province_county = 'NorthCarolina' EXCEPT SELECT DISTINCT T3.last_name FROM Students AS T3 JOIN Student_Enrolment AS T4 ON T3.student_id = T4.student_id", + "pred_sql": "SELECT T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.state_province_county = \"North Carolina\" EXCEPT SELECT T2.last_name FROM students AS T2 JOIN student_enrolment_courses AS T3 ON T2.student_id = T3.student_course_id JOIN degree_programs AS T4 ON T4.degree_program_id = T3.degree_program_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:551", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date and id of the student record with at least 2 curriculum results.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.transcript_date , T1.student_id FROM Transcripts AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_course_id = T2.student_course_id JOIN Students AS T3 ON T2.student_enrolment_id = T3.student_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:552", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with at least 2 curriculums listed?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_id = T2.student_course_id GROUP BY T1.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:553", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the man with the given name Timmothy and the family name Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM students WHERE first_name = \"Timmothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:554", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the phone number of the student named Timothy Ward?", + "gold_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = 'Timmothy' AND last_name = 'Ward'", + "pred_sql": "SELECT cell_mobile_number FROM Students WHERE first_name = \"Timothy\" AND last_name = \"Ward\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:555", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the first student to register? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:556", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the first student to register?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "pred_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:557", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Who is the earliest graduate of the school? List the given name, middle name and family name.", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM Students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_id WHERE T2.transcript_date = (SELECT min(transcript_date) FROM transcripts) AND T1.date_first_registered = (SELECT min(date_first_registered) FROM students)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:558", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given, middle, and family name of the earliest school graduate?", + "gold_sql": "SELECT first_name , middle_name , last_name FROM Students ORDER BY date_left ASC LIMIT 1", + "pred_sql": "SELECT T1.first_name , T1.middle_name , T1.last_name FROM students AS T1 JOIN transcripts AS T2 ON T1.student_id = T2.student_id JOIN student_enrolment_courses AS T3 ON T2.transcript_id = T3.transcript_id WHERE T3.semester_id = 1 ORDER BY T1.date_first_registered LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:559", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Whose permanent address is different from his or her current address? List his or her given name.", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:560", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the given name of the student whose permanent address is different from his or her current one?", + "gold_sql": "SELECT first_name FROM Students WHERE current_address_id != permanent_address_id", + "pred_sql": "SELECT first_name FROM students WHERE permanent_address_id != current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:561", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Which place holds the most number of students currently? List the place id and all lines.", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 , T1.line_3 FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:562", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id, line 1, and line 2 of the address with the most students?", + "gold_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.address_id , T1.line_1 , T1.line_2 FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id GROUP BY T1.address_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:563", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "On average, when were the student record printed?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(transcript_date) FROM transcripts WHERE transcript_type = 'student'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:564", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the average student record date?", + "gold_sql": "SELECT avg(transcript_date) FROM Transcripts", + "pred_sql": "SELECT avg(date_first_registered) FROM Students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:565", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When is the first student record released? List the date and details.", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT date_first_registered , other_student_details FROM Students ORDER BY date_first_registered ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:566", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the earliest date of a transcript release, and what particulars can you tell me?", + "gold_sql": "SELECT transcript_date , other_details FROM Transcripts ORDER BY transcript_date ASC LIMIT 1", + "pred_sql": "SELECT min(transcript_date) , max(transcript_date) FROM transcripts", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:567", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student record are released?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:568", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many student records are listed?", + "gold_sql": "SELECT count(*) FROM Transcripts", + "pred_sql": "SELECT count(*) FROM students", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:569", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the last student record release date?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(T2.transcript_date) FROM transcripts AS T1 JOIN students AS T2 ON T1.transcript_id = T2.transcript_id WHERE T2.student_id IN (SELECT student_id FROM students WHERE date_first_registered = (SELECT min(date_first_registered) FROM students))", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:570", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "When was the last student record released?", + "gold_sql": "SELECT transcript_date FROM Transcripts ORDER BY transcript_date DESC LIMIT 1", + "pred_sql": "SELECT max(date_first_registered) FROM Students;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:571", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many times at most can a curriculum enrollment result show in different student records? Also show the curriculum enrollment id.", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.student_enrolment_id FROM Student_Enrolment AS T1 JOIN Student_Enrolment_Courses AS T2 ON T1.student_enrolment_id = T2.student_enrolment_id GROUP BY T1.student_enrolment_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:572", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the maximum number of times that a curriculum shows up in different student records and what is that curriculum's enrollment id?", + "gold_sql": "SELECT count(*) , student_course_id FROM Transcript_Contents GROUP BY student_course_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , T1.course_id FROM courses AS T1 JOIN student_enrolment_courses AS T2 ON T1.course_id = T2.course_id GROUP BY T1.course_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:573", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Show the date of the student record which shows the least number of results, also list the id.", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered FROM Students AS T1 JOIN Transcript_Contents AS T2 ON T1.student_course_id = T2.student_course_id GROUP BY T1.student_id ORDER BY count(*) LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:574", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the date and id of the student record with the least number of results?", + "gold_sql": "SELECT T2.transcript_date , T1.transcript_id FROM Transcript_Contents AS T1 JOIN Transcripts AS T2 ON T1.transcript_id = T2.transcript_id GROUP BY T1.transcript_id ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.date_first_registered , T1.student_id FROM Students AS T1 JOIN Transcript_Contents AS T2 ON T1.student_course_id = T2.student_course_id GROUP BY T1.student_id ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:575", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the academic session when both Master students and Bachelor students got enrolled in.", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = 'Master' INTERSECT SELECT T2.semester_name FROM students AS T1 JOIN student_enrolment AS T2 ON T1.student_id = T2.student_id WHERE T1.first_name = 'Bachelor'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:576", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the id of the academic session that had both Masters and Bachelors students enrolled?", + "gold_sql": "SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Master' INTERSECT SELECT DISTINCT T2.semester_id FROM Degree_Programs AS T1 JOIN Student_Enrolment AS T2 ON T1.degree_program_id = T2.degree_program_id WHERE degree_summary_name = 'Bachelor'", + "pred_sql": "SELECT T1.semester_id FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN student_enrolment_courses AS T3 ON T1.student_enrolment_id = T3.student_enrolment_id JOIN courses AS T4 ON T3.course_id = T4.course_id WHERE T4.course_name = 'Masters' INTERSECT SELECT T1.semester_id FROM student_enrolment AS T1 JOIN students AS T2 ON T1.student_id = T2.student_id JOIN student_enrolment_courses AS T3 ON T1.student_enrolment_id = T3.student_enrolment_id JOIN courses AS T4 ON T3.course_id = T4.course_id WHERE T4.course_name = 'Bachelors'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:577", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "How many different places do the students currently live?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT count(DISTINCT T1.address_id) FROM Addresses AS T1 JOIN Students AS T2 ON T1.address_id = T2.current_address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:578", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the different places that have students living there?", + "gold_sql": "SELECT count(DISTINCT current_address_id) FROM Students", + "pred_sql": "SELECT DISTINCT T2.line_1 FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:579", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "List all the student particulars in reversed lexicographical order.", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT * FROM Students ORDER BY first_name , last_name;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:580", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What other particulars can you tell me about students in reverse alphabetical order?", + "gold_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "pred_sql": "SELECT other_student_details FROM Students ORDER BY other_student_details DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:581", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Describe the section h.", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT DISTINCT section_name FROM Sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:582", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What is the description for the section named h?", + "gold_sql": "SELECT section_description FROM Sections WHERE section_name = 'h'", + "pred_sql": "SELECT section_description FROM sections WHERE section_name = \"h\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:583", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "Find the given name of the students who permanently live in the country Haiti or have the phone number 09700166582.", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id WHERE T1.country = \"Haiti\" UNION SELECT T2.first_name , T2.last_name FROM addresses AS T1 JOIN students AS T2 ON T1.address_id = T2.permanent_address_id AND T2.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:584", + "benchmark": "spider_syn", + "split": "test", + "db_id": "student_transcripts_tracking", + "question": "What are the given names of the students who live in Haiti permanently or have the phone number 09700166582?", + "gold_sql": "SELECT T1.first_name FROM Students AS T1 JOIN Addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = 'Haiti' UNION SELECT first_name FROM Students WHERE cell_mobile_number = '09700166582'", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.permanent_address_id = T2.address_id WHERE T2.country = \"Haiti\" UNION SELECT T2.first_name , T2.last_name FROM students AS T1 JOIN addresses AS T2 ON T1.current_address_id = T2.address_id WHERE T1.cell_mobile_number = \"09700166582\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:585", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations in alphabetical order.", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:586", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of the animations sorted alphabetically?", + "gold_sql": "SELECT Title FROM Cartoon ORDER BY title", + "pred_sql": "SELECT title FROM cartoon ORDER BY title", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:587", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List all animation directed by \"Ben Jones\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:588", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animations directed by Ben Jones?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\";", + "pred_sql": "SELECT Title FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:589", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations were written by \"Joseph Kuhr\"?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:590", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the number of animations written by Joseph Kuhr?", + "gold_sql": "SELECT count(*) FROM Cartoon WHERE Written_by = \"Joseph Kuhr\";", + "pred_sql": "SELECT count(*) FROM cartoon WHERE directed_by = \"Joseph Kuhr\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:591", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "list all animation and their directors ordered by their airdate", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY Original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:592", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name and directors of all the animation that are ordered by released date?", + "gold_sql": "SELECT title , Directed_by FROM Cartoon ORDER BY Original_air_date", + "pred_sql": "SELECT title , directed_by FROM cartoon ORDER BY original_air_date", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:593", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animation directed by \"Ben Jones\" or \"Brandon Vietti\".", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT Title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:594", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the names of all animation directed by Ben Jones or Brandon Vietti?", + "gold_sql": "SELECT Title FROM Cartoon WHERE Directed_by = \"Ben Jones\" OR Directed_by = \"Brandon Vietti\";", + "pred_sql": "SELECT title FROM cartoon WHERE directed_by = \"Ben Jones\" OR directed_by = \"Brandon Vietti\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:595", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Which country has the most of TV Channels? List the country name and number of TV Channels it has.", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , COUNT(*) FROM tv_channel GROUP BY Country ORDER BY COUNT(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:596", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the State with the most number of TV Channels and how many does it have?", + "gold_sql": "SELECT Country , count(*) FROM TV_Channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1;", + "pred_sql": "SELECT Country , count(*) FROM TV_channel GROUP BY Country ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:597", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the number of different serial names and contents in the TV Channel table.", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(*) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:598", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many different serial and contents are listed in the TV Channel table?", + "gold_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_Channel;", + "pred_sql": "SELECT count(DISTINCT series_name) , count(DISTINCT content) FROM TV_channel", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:599", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:600", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the content of the series Sky Radio?", + "gold_sql": "SELECT Content FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Content FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:601", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the Package Option of TV Channel with serial name \"Sky Radio\"?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:602", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the Package Options of the TV Channels whose series names are Sky Radio?", + "gold_sql": "SELECT Package_Option FROM TV_Channel WHERE series_name = \"Sky Radio\";", + "pred_sql": "SELECT Package_Option FROM TV_channel WHERE series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:603", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channel using language English?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:604", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many TV Channels use the English language?", + "gold_sql": "SELECT count(*) FROM TV_Channel WHERE LANGUAGE = \"English\";", + "pred_sql": "SELECT count(*) FROM TV_channel WHERE language = \"english\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:605", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the language used least number of TV Channel. List language and number of TV Channel.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:606", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the languages used by the least number of TV Channels and how many channels use it?", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE ORDER BY count(*) ASC LIMIT 1;", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language ORDER BY COUNT(*) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:607", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List each language and the number of TV Channels using it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:608", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "For each language, list the number of TV Channels that use it.", + "gold_sql": "SELECT LANGUAGE , count(*) FROM TV_Channel GROUP BY LANGUAGE", + "pred_sql": "SELECT Language , COUNT(*) FROM TV_channel GROUP BY Language", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:609", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel that shows the cartoon \"The Rise of the Blue Beetle!\"? List the TV Channel's series name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT t3.channel , t2.series_name FROM cartoon AS t1 JOIN tv_series AS t2 ON t1.channel = t2.channel JOIN tv_channel AS t3 ON t2.id = t3.id WHERE t1.title = \"The Rise of the Blue Beetle!\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:610", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name of the TV Channel that shows the cartoon \"The Rise of the Blue Beetle\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T2.Title = \"The Rise of the Blue Beetle!\";", + "pred_sql": "SELECT T1.Channel FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.Title = \"The Rise of the Blue Beetle\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:611", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the name of all animations showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM TV_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.Series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:612", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the name of all the animations that are on the TV Channel with the series name \"Sky Radio\"?", + "gold_sql": "SELECT T2.Title FROM TV_Channel AS T1 JOIN Cartoon AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T2.Title FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T1.Series_Name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:613", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series sorted by rating.", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT Episode FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:614", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are all of the episodes ordered by ratings?", + "gold_sql": "SELECT Episode FROM TV_series ORDER BY rating", + "pred_sql": "SELECT * FROM TV_series ORDER BY Rating", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:615", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List top 3 highest score TV series. List the TV series's Episode and score.", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT T1.Episode , T1.Rating FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:616", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are 3 most highly rated episodes in the TV series table and what were those scores?", + "gold_sql": "SELECT Episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3;", + "pred_sql": "SELECT episode , Rating FROM TV_series ORDER BY Rating DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:617", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is minimum and maximum share of TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT min(Share) , max(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:618", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the maximum and minimum share for the TV series?", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM TV_series;", + "pred_sql": "SELECT max(Share) , min(Share) FROM TV_series", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:619", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the airdate of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:620", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "When did the episode \"A Love of a Lifetime\" released?", + "gold_sql": "SELECT Air_Date FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Episode FROM TV_series AS T1 JOIN Cartoon AS T2 ON T1.episode = T2.episode WHERE T2.Title = \"A Love of a Lifetime\" LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:621", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is Weekly Rank of TV series with Episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:622", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the score per week for the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT Weekly_Rank FROM TV_series WHERE Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T2.Weekly_Rank FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:623", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the TV Channel of TV serial with Episode \"A Love of a Lifetime\"? List the TV Channel's serial name.", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT T1.channel , T2.series_name FROM TV_channel AS T1 JOIN tv_series AS T2 ON T1.id = T2.channel WHERE T2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:624", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name that has the episode \"A Love of a Lifetime\"?", + "gold_sql": "SELECT T1.series_name FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T2.Episode = \"A Love of a Lifetime\";", + "pred_sql": "SELECT t1.series_name FROM TV_channel AS t1 JOIN tv_series AS t2 ON t1.id = t2.episode WHERE t2.episode = \"A Love of a Lifetime\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:625", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "List the Episode of all TV series showed on TV Channel with series name \"Sky Radio\".", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.series_name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:626", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the episode for the TV series named \"Sky Radio\"?", + "gold_sql": "SELECT T2.Episode FROM TV_Channel AS T1 JOIN TV_series AS T2 ON T1.id = T2.Channel WHERE T1.series_name = \"Sky Radio\";", + "pred_sql": "SELECT T1.Episode FROM TV_series AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T2.Series_Name = \"Sky Radio\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:627", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the number of animations directed by each of the listed directors.", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:628", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "How many animations did each director create?", + "gold_sql": "SELECT count(*) , Directed_by FROM cartoon GROUP BY Directed_by", + "pred_sql": "SELECT directed_by , count(*) FROM cartoon GROUP BY directed_by", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:629", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the production number and channel of the most recently released cartoon.", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM Cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:630", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the produdction number and channel of the most recent cartoon?", + "gold_sql": "SELECT production_code , channel FROM cartoon ORDER BY original_air_date LIMIT 1", + "pred_sql": "SELECT Production_code , Channel FROM cartoon ORDER BY Original_air_date DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:631", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the package choice and serial name of the TV channel that has HD TV.", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM TV_channel WHERE Content = \"HD TV\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:632", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options and the name of the serial for the TV Channel that supports HD TV?", + "gold_sql": "SELECT package_option , series_name FROM TV_Channel WHERE hight_definition_TV = \"yes\"", + "pred_sql": "SELECT Package_Option , series_name FROM tv_channel WHERE pixel_aspect_ratio_PAR = \"HD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:633", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are playing some animation written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = 'Todd Casey' AND t2_written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:634", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the State that have animations on TV that were written by Todd Casey?", + "gold_sql": "SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT T1.State FROM cartoon AS T1 JOIN TV_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Todd\" AND T1.written_by = \"Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:635", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "which countries' tv channels are not playing any animation written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT country FROM tv_channel EXCEPT SELECT t1.country FROM tv_channel AS t1 JOIN cartoon AS t2 ON t1.id = t2.channel WHERE t2.directed_by = \"Todd Casey\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:636", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the States that are not playing animations written by Todd Casey?", + "gold_sql": "SELECT country FROM TV_Channel EXCEPT SELECT T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.written_by = 'Todd Casey'", + "pred_sql": "SELECT title FROM cartoon EXCEPT SELECT T1.title FROM cartoon AS T1 JOIN Cartoon AS T2 ON T1.directed_by = T2.directed_by WHERE T2.written_by = 'Todd Casey'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:637", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "Find the serial name and State of the tv channel that is playing some animation directed by Ben Jones and Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT t2.series_name , t2.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Ben Jones\" INTERSECT SELECT t2.series_name , t2.channel FROM cartoon AS t1 JOIN tv_channel AS t2 ON t1.channel = t2.id WHERE t1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:638", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the serial name and nation of all TV channels that are playing animations directed by Ben Jones and animations directed by Michael Chang?", + "gold_sql": "SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Michael Chang' INTERSECT SELECT T1.series_name , T1.country FROM TV_Channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.Channel WHERE T2.directed_by = 'Ben Jones'", + "pred_sql": "SELECT T2.series_name , T2.country FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Ben Jones\" INTERSECT SELECT T2.series_name , T2.country FROM cartoon AS T1 JOIN tv_channel AS T2 ON T1.channel = T2.id WHERE T1.directed_by = \"Michael Chang\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:639", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the pixel aspect ratio and nation of the tv channels that do not use English.", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_channel WHERE Language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:640", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What is the pixel aspect ratio and nation of origin for all TV channels that do not use English?", + "gold_sql": "SELECT Pixel_aspect_ratio_PAR , country FROM tv_channel WHERE LANGUAGE != 'English'", + "pred_sql": "SELECT Pixel_aspect_ratio_PAR , Country FROM TV_Channel WHERE Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:641", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find id of the tv channels that from the States where have more than two tv channels.", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel GROUP BY country HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:642", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of all tv channels that have more than 2 TV channels?", + "gold_sql": "SELECT id FROM tv_channel where country in(select country from tv_channel GROUP BY country HAVING count(*) > 2)", + "pred_sql": "SELECT id FROM tv_channel GROUP BY id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:643", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the id of tv channels that do not play any animation directed by Ben Jones.", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:644", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the ids of the TV channels that do not have any animations directed by Ben Jones?", + "gold_sql": "SELECT id FROM TV_Channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones'", + "pred_sql": "SELECT id FROM tv_channel EXCEPT SELECT channel FROM cartoon WHERE directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:645", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "find the package option of the tv channel that do not have any animation directed by Ben Jones.", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT package_option FROM tv_channel EXCEPT SELECT T1.package_option FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:646", + "benchmark": "spider_syn", + "split": "test", + "db_id": "tvshow", + "question": "What are the package options of all tv channels that are not playing any animations directed by Ben Jones?", + "gold_sql": "SELECT package_option FROM TV_Channel WHERE id NOT IN (SELECT channel FROM cartoon WHERE directed_by = 'Ben Jones')", + "pred_sql": "SELECT Package_Option FROM tv_channel EXCEPT SELECT T1.Package_Option FROM tv_channel AS T1 JOIN cartoon AS T2 ON T1.id = T2.channel WHERE T2.directed_by = \"Ben Jones\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:647", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many car gamers are there?", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE height > 1.75", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:648", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of car gamers.", + "gold_sql": "SELECT count(*) FROM poker_player", + "pred_sql": "SELECT count(*) FROM people WHERE nationality = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:649", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the earnings of poker players in descending order.", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:650", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the earnings of poker players, ordered descending by value?", + "gold_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "pred_sql": "SELECT Earnings FROM poker_player ORDER BY Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:651", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the final tables made and the best finishes of car gamers.", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT FINAL_TABLE_MADE , best_finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:652", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the final tables made and best finishes for all car gamers?", + "gold_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "pred_sql": "SELECT Final_Table_Made , Best_Finish FROM poker_player", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:653", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers?", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE People_ID IN (SELECT People_ID FROM car_gameer);", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:654", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the average incomes across all car gamers.", + "gold_sql": "SELECT avg(Earnings) FROM poker_player", + "pred_sql": "SELECT avg(Earnings) FROM poker_player WHERE Nationality = \"Car Gammer\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:655", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the car gamer with the highest incomes?", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:656", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the gamer with the greatest revenues.", + "gold_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "pred_sql": "SELECT Money_Rank FROM poker_player ORDER BY Earnings DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:657", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the maximum number of last tables made among car gamers with revenues less than 200000?", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:658", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the maximum final tables made across all car gamers who have revenues below 200000.", + "gold_sql": "SELECT max(Final_Table_Made) FROM poker_player WHERE Earnings < 200000", + "pred_sql": "SELECT max(final_table_made) FROM poker_player WHERE earnings < 200000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:659", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:660", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of all the car gamers.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Final_Table_Made = \"Car Game\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:661", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers whose incomes is higher than 300000?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:662", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the names of car gamers who have revenues above 300000.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Earnings > 300000", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Earnings > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:663", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of car gamers ordered by the final tables made in ascending order.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:664", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers, ordered ascending by the number of final tables they have made?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Final_Table_Made", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Final_Table_Made", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:665", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the birth date of the car gamers with the lowest revenues?", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T1.Name , T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:666", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the birth date of the car gamers with the lowest revenues.", + "gold_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings ASC LIMIT 1", + "pred_sql": "SELECT T1.Birth_Date FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:667", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the money rank of the tallest car gamer?", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T1.Money_Rank FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:668", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the money rank of the car gamer with the greatest height.", + "gold_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "pred_sql": "SELECT T2.Money_Rank FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Height DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:669", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the average revenues of car gamers with height higher than 200?", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:670", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give average revenues of car gamers who are taller than 200.", + "gold_sql": "SELECT avg(T2.Earnings) FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID WHERE T1.Height > 200", + "pred_sql": "SELECT avg(T1.Earnings) FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID WHERE T2.Height > 200", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:671", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of car gamers in descending order of revenues?", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:672", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the names of car gamers sorted by their revenues descending.", + "gold_sql": "SELECT T1.Name FROM people AS T1 JOIN poker_player AS T2 ON T1.People_ID = T2.People_ID ORDER BY T2.Earnings DESC", + "pred_sql": "SELECT T2.Name FROM poker_player AS T1 JOIN people AS T2 ON T1.People_ID = T2.People_ID ORDER BY T1.Earnings DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:673", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are different country of people and the corresponding number of people from each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:674", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many people are there of each country?", + "gold_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "pred_sql": "SELECT Nationality , COUNT(*) FROM people GROUP BY Nationality", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:675", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What is the most common country of people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:676", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Give the country that is most common across all people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:677", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the countries that are shared by at least two people?", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:678", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Return the countries for which there are two or more people.", + "gold_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "pred_sql": "SELECT Nationality FROM people GROUP BY Nationality HAVING COUNT(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:679", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names and birth dates of people in ascending alphabetical order of name.", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:680", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names and birth dates of people, ordered by their names in alphabetical order?", + "gold_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "pred_sql": "SELECT Name , Birth_Date FROM people ORDER BY Name ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:681", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Show names of people whose nationality is not \"Russia\".", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:682", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who are not from Russia?", + "gold_sql": "SELECT Name FROM people WHERE Nationality != \"Russia\"", + "pred_sql": "SELECT Name FROM people WHERE Nationality != 'Russia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:683", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "List the names of people that are not car gamers.", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Car Game\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:684", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "What are the names of people who do not car gamer?", + "gold_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player)", + "pred_sql": "SELECT Name FROM people WHERE People_ID NOT IN (SELECT People_ID FROM poker_player WHERE Final_Table_Made = \"Gamer\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:685", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "How many distinct countries are there?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:686", + "benchmark": "spider_syn", + "split": "test", + "db_id": "poker_player", + "question": "Count the number of different countries.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM people", + "pred_sql": "SELECT count(DISTINCT Nationality) FROM people", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:687", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many states are there?", + "gold_sql": "SELECT count(*) FROM area_code_state", + "pred_sql": "SELECT count(DISTINCT state) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:688", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the competitor numbers and names, ordered by competitor name descending.", + "gold_sql": "SELECT contestant_number , contestant_name FROM contestants ORDER BY contestant_name DESC", + "pred_sql": "SELECT contestant_number , contestant_name FROM CONTESTANTS ORDER BY contestant_name DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:689", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the vote ids, telephone numbers and states of all votes.", + "gold_sql": "SELECT vote_id , phone_number , state FROM votes", + "pred_sql": "SELECT vote_id , phone_number , state FROM VOTES", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:690", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the maximum and minimum values of area codes?", + "gold_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "pred_sql": "SELECT max(area_code) , min(area_code) FROM area_code_state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:691", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is last date created of votes from the state 'CA'?", + "gold_sql": "SELECT max(created) FROM votes WHERE state = 'CA'", + "pred_sql": "SELECT max(created) FROM VOTES WHERE state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:692", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the names of the participants whose names are not 'Jessie Alloway'", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name != 'Jessie Alloway'", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS EXCEPT SELECT contestant_name FROM CONTESTANTS WHERE contestant_name = 'Jessie Alloway'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:693", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the distinct states and set up time of all votes?", + "gold_sql": "SELECT DISTINCT state , created FROM votes", + "pred_sql": "SELECT DISTINCT T2.state , T1.created FROM VOTES AS T1 JOIN AREA_CODE_STATE AS T2 ON T1.state = T2.state", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:694", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the participant numbers and names of the participants who had at least two votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "pred_sql": "SELECT T1.contestant_number , T2.contestant_name FROM CONTESTANTS AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:695", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Of all the competitors who got voted, what is the competitor number and name of the competitor who got least votes?", + "gold_sql": "SELECT T1.contestant_number , T1.contestant_name FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T1.contestant_number ORDER BY count(*) ASC LIMIT 1", + "pred_sql": "SELECT T1.contestant_number , T1.contestant_name FROM CONTESTANTS AS T1 JOIN VOTES AS T2 ON T1.contestant_number = T2.contestant_number GROUP BY T2.contestant_number ORDER BY count(*) ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:696", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the number of votes from nation 'NY' or 'CA'?", + "gold_sql": "SELECT count(*) FROM votes WHERE state = 'NY' OR state = 'CA'", + "pred_sql": "SELECT count(*) FROM VOTES WHERE state = 'NY' OR state = 'CA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:697", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "How many competitors did not get voted?", + "gold_sql": "SELECT count(*) FROM contestants WHERE contestant_number NOT IN ( SELECT contestant_number FROM votes )", + "pred_sql": "SELECT count(*) FROM CONTESTANTS WHERE contestant_number NOT IN (SELECT contestant_number FROM VOTES)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:698", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What is the area number in which the most voters voted?", + "gold_sql": "SELECT T1.area_code FROM area_code_state AS T1 JOIN votes AS T2 ON T1.state = T2.state GROUP BY T1.area_code ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT count(*) , state FROM VOTES GROUP BY state ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:699", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "What are the set up dates, states, and telephone numbers of the votes that were for the competitor named 'Tabatha Gehling'?", + "gold_sql": "SELECT T2.created , T2.state , T2.phone_number FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number WHERE T1.contestant_name = 'Tabatha Gehling'", + "pred_sql": "SELECT T1.state , T1.phone_number , T1.created FROM VOTES AS T1 JOIN CONTESTANTS AS T2 ON T1.contestant_number = T2.contestant_number WHERE T2.contestant_name = 'Tabatha Gehling'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:700", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "List the area codes in which voters voted both for the participant 'Tabatha Gehling' and the participant 'Kelly Clauss'.", + "gold_sql": "SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Tabatha Gehling' INTERSECT SELECT T3.area_code FROM contestants AS T1 JOIN votes AS T2 ON T1.contestant_number = T2.contestant_number JOIN area_code_state AS T3 ON T2.state = T3.state WHERE T1.contestant_name = 'Kelly Clauss'", + "pred_sql": "SELECT T1.area_code FROM AREA_CODE_STATE AS T1 JOIN VOTES AS T2 ON T1.state = T2.state WHERE T2.contestant_number = 101 AND T2.state = 10 AND T2.contestant_number = 102", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:701", + "benchmark": "spider_syn", + "split": "test", + "db_id": "voter_1", + "question": "Return the names the competitors whose names contain the substring 'Al'.", + "gold_sql": "SELECT contestant_name FROM contestants WHERE contestant_name LIKE \"%Al%\"", + "pred_sql": "SELECT contestant_name FROM CONTESTANTS WHERE contestant_name LIKE '%Al%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:702", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of all the States that became sovereign after 1950?", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independYear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:703", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of the nations that were founded after 1950.", + "gold_sql": "SELECT Name FROM country WHERE IndepYear > 1950", + "pred_sql": "SELECT name FROM country WHERE independyear > 1950", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:704", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have a republic as their form of government?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:705", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many nations have governments that are republics?", + "gold_sql": "SELECT count(*) FROM country WHERE GovernmentForm = \"Republic\"", + "pred_sql": "SELECT count(DISTINCT country) FROM country WHERE governmentform = 'Republic'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:706", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the State in the Caribbean region?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(t1.surfacearea) FROM country AS t1 JOIN city AS t2 ON t1.code = t2.capital WHERE t1.name 在 (t2.district = \"Caribbean\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:707", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How much territory do the countires in the Caribbean cover together?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Region = \"Caribbean\"", + "pred_sql": "SELECT sum(T1.SurfaceArea) FROM country AS T1 JOIN country AS T2 ON T1.Region = T2.Region WHERE T2.Name = \"Caribbean\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:708", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent is Anguilla in?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT continent FROM country WHERE name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:709", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the continent name which Anguilla belongs to?", + "gold_sql": "SELECT Continent FROM country WHERE Name = \"Anguilla\"", + "pred_sql": "SELECT t1.continent FROM country AS t1 JOIN country AS t2 ON t1.code = t2.code WHERE t2.name = \"Anguilla\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:710", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which region is the city Kabul located in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T2.Region FROM city AS T1 JOIN country AS T2 ON T1.Capital = T2.Capital WHERE T1.Name = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:711", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region is Kabul in?", + "gold_sql": "SELECT Region FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Kabul\"", + "pred_sql": "SELECT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T1.Capital = \"Kabul\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:712", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:713", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What language is predominantly spoken in Aruba?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\" ORDER BY Percentage DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\" ORDER BY T1.Percentage DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:714", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the population and lifespan in Brazil?", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT T1.Population , T1.LifeExpectancy FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:715", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give me Brazil's population and lifespan.", + "gold_sql": "SELECT Population , LifeExpectancy FROM country WHERE Name = \"Brazil\"", + "pred_sql": "SELECT population , lifeexpectancy FROM country WHERE name = \"Brazil\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:716", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the region and number of people of Angola?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Regions , COUNT(*) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.Name = \"Angola\" GROUP BY T1.Regions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:717", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What region does Angola belong to and what is its number of residents?", + "gold_sql": "SELECT Population , Region FROM country WHERE Name = \"Angola\"", + "pred_sql": "SELECT T1.Regions , COUNT(*) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T2.name = \"Angola\" GROUP BY T1.Regions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:718", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan for countries in the region of Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:719", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How long is the people’s average lifespan in Central Africa?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Region = \"Central Africa\"", + "pred_sql": "SELECT avg(people.lifeexpectancy) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Central Africa\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:720", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the name of nation that has the shortest lifespan in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' ORDER BY lifeexpectancy DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:721", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State in Asia with the lowest lifespan.", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" ORDER BY LifeExpectancy LIMIT 1", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T2.Continent = \"Asia\" ORDER BY T1.LifeExpectancy LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:722", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and maximum GNP in Asia?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT sum(T1.Population) , max(T2.GNP) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:723", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Asia, and what is the largest GNP among them?", + "gold_sql": "SELECT sum(Population) , max(GNP) FROM country WHERE Continent = \"Asia\"", + "pred_sql": "SELECT max(gnp) , sum(population) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:724", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average lifespan in African nations that are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T2.Region = \"Republic\" AND T1.Name = \"African\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:725", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the average lifespan for nations in Africa which are republics?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Continent = \"Africa\" AND GovernmentForm = \"Republic\"", + "pred_sql": "SELECT avg(T1.LifeExpectancy) FROM country AS T1 JOIN country AS T2 ON T1.Code = T2.Code WHERE T1.Continent = \"Africa\" AND T2.Region = \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:726", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total territory of the continents Asia and Europe?", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(surfacearea) FROM country WHERE name = 'Asia' OR name = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:727", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total territory covered by countries in Asia or Europe.", + "gold_sql": "SELECT sum(SurfaceArea) FROM country WHERE Continent = \"Asia\" OR Continent = \"Europe\"", + "pred_sql": "SELECT sum(t1.SurfaceArea) FROM country AS t1 JOIN country AS t2 ON t1.Code = t2.Code WHERE t1.Continent = \"Asia\" OR t1.Continent = \"Europe\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:728", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT Population FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:729", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of residents of Gelderland district?", + "gold_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "pred_sql": "SELECT sum(Population) FROM city WHERE District = \"Gelderland\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:730", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the average GNP and total number of people in all States whose government is US territory?", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE continent = 'North' OR continent = 'South' OR region = 'West' OR region = 'East'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:731", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean GNP and total number of people of nations which are considered US territory.", + "gold_sql": "SELECT avg(GNP) , sum(population) FROM country WHERE GovernmentForm = \"US Territory\"", + "pred_sql": "SELECT avg(gnp) , count(*) FROM country WHERE region = 'US'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:732", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many unique languages are spoken in the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:733", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct languages used around the world?", + "gold_sql": "SELECT count(DISTINCT LANGUAGE) FROM countrylanguage", + "pred_sql": "SELECT count(DISTINCT language) FROM countrylanguage", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:734", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many type of governments are in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:735", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many different types of governments are there in Africa?", + "gold_sql": "SELECT count(DISTINCT GovernmentForm) FROM country WHERE Continent = \"Africa\"", + "pred_sql": "SELECT count(DISTINCT governmentform) FROM country WHERE continent = 'Africa'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:736", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of languages used in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT sum(T2.Percentage) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:737", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many languages are spoken in Aruba?", + "gold_sql": "SELECT COUNT(T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Aruba\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Aruba\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:738", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages does Afghanistan have?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Afghanistan' AND T1.isofficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:739", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many official languages are spoken in Afghanistan?", + "gold_sql": "SELECT COUNT(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = \"Afghanistan\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Afghanistan\" AND T1.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:740", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is name of the nation that speaks the largest number of languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:741", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name of the State that uses the greatest amount of languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode ORDER BY sum(T2.percentage) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:742", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent has the most diverse languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:743", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which continent speaks the most languages?", + "gold_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Continent ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Continent FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:744", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many States speak both English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"English\" INTERSECT SELECT count(*) FROM countrylanguage WHERE IsOfficial = 1 AND Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:745", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of countries that use English and Dutch?", + "gold_sql": "SELECT COUNT(*) FROM (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\")", + "pred_sql": "SELECT count(*) FROM country WHERE Language = \"English\" INTERSECT SELECT count(*) FROM country WHERE Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:746", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States speak both English and French?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" INTERSECT SELECT T1.Name FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:747", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of countries that speak both English and French.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:748", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of States where both English and French are official languages?", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:749", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations with English and French as official languages.", + "gold_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\" INTERSECT SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"French\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" INTERSECT SELECT T1.Name , T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:750", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the number of distinct continents where Chinese is spoken?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT T1.Continent) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:751", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many continents speak Chinese?", + "gold_sql": "SELECT COUNT( DISTINCT Continent) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Chinese\"", + "pred_sql": "SELECT count(DISTINCT t1.continent) FROM countrylanguage AS t1 JOIN country AS t2 ON t1.countrycode = t2.code2 WHERE t1.language = \"Chinese\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:752", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the regions that use English or Dutch?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"English\" OR T1.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:753", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which regions speak Dutch or English?", + "gold_sql": "SELECT DISTINCT T1.Region FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "pred_sql": "SELECT T1.Region FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T1.Language = \"Dutch\" OR T1.Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:754", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations where either English or Dutch is the official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:755", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which nations have either English or Dutch as an official language?", + "gold_sql": "SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND IsOfficial = \"T\" UNION SELECT * FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Dutch\" AND IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.IsOfficial = 1 AND T2.Language = \"English\" OR T2.Language = \"Dutch\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:756", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is the most popular on the Asian continent?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:757", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language that is used by the largest number of Asian nations?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Asia\" GROUP BY T2.Language ORDER BY COUNT (*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Name = \"Asia\" GROUP BY T1.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:758", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which languages are spoken by only one country in republic governments?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Region = 'Republic' GROUP BY T1.Language HAVING COUNT(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:759", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What languages are only used by a single country with a republic government?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.GovernmentForm = \"Republic\" GROUP BY T2.Language HAVING COUNT(*) = 1", + "pred_sql": "SELECT DISTINCT l1.lang FROM countrylanguage AS l1 JOIN country AS l2 ON l1.countrycode = l2.code WHERE l2.region = \"Republic\" GROUP BY l1.lang ORDER BY count(*) = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:760", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the town with the largest number of people that uses English.", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" GROUP BY T1.Name ORDER BY T1.Population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:761", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the most populace city that speaks English?", + "gold_sql": "SELECT T1.Name , T1.Population FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.Language = \"English\" ORDER BY T1.Population DESC LIMIT 1", + "pred_sql": "SELECT t1.name FROM city AS t1 JOIN countrylanguage AS t2 ON t1.capital = t2.countrycode WHERE t2.Language = \"English\" ORDER BY t1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:762", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the name, populace and expected life length of asian country with the largest area?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM country AS T1 JOIN country AS T2 ON T1.code = T2.code WHERE T1.name = 'Asia' ORDER BY T1.SurfaceArea DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:763", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, number of residents, and lifespan of the largest Asian country by land?", + "gold_sql": "SELECT Name , Population , LifeExpectancy FROM country WHERE Continent = \"Asia\" ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT T1.name , T1.population , T1.lifeexpectancy FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.name = 'Asia' ORDER BY T1.population DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:764", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is average lifespan in the nations where English is not the official language?", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(%) FROM country WHERE IsOfficial = 0 INTERSECT SELECT avg(%) FROM countrylanguage WHERE Language = \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:765", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the mean lifespan of nations in which English is not the official language.", + "gold_sql": "SELECT avg(LifeExpectancy) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" AND T2.IsOfficial = \"T\")", + "pred_sql": "SELECT avg(%) FROM country WHERE IsOfficial = 0 AND CountryCode NOT IN (SELECT CountryCode FROM countrylanguage WHERE IsOfficial = 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:766", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people living in the nations that do not use English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT T1.countrycode FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code2 WHERE T1.IsOfficial = 0)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:767", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many people live in nations that do not speak English?", + "gold_sql": "SELECT sum(Population) FROM country WHERE Name NOT IN (SELECT T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\")", + "pred_sql": "SELECT sum(population) FROM city WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:768", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language spoken in the country whose head of state is Beatrix?", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T2.IsOfficial , T1.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:769", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the official language used in the country the name of whose leader of country is Beatrix.", + "gold_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.HeadOfState = \"Beatrix\" AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.HeadOfState = \"Beatrix\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:770", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of unique official languages spoken in the nations that are founded before 1930?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT count(*) FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T2.indepyear < 1930", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:771", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "For the nations founded before 1930, what is the total number of distinct official languages?", + "gold_sql": "SELECT count(DISTINCT T2.Language) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE IndepYear < 1930 AND T2.IsOfficial = \"T\"", + "pred_sql": "SELECT sum(IsOfficial) FROM countrylanguage WHERE country Code < 'France' AND country Code <= 'United Kingdom'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:772", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nations that have greater territory than any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:773", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which countries have greater territory than that of any country in Europe?", + "gold_sql": "SELECT Name FROM country WHERE SurfaceArea > (SELECT min(SurfaceArea) FROM country WHERE Continent = \"Europe\")", + "pred_sql": "SELECT name FROM country WHERE surfacearea > (SELECT max(surfacearea) FROM country WHERE continent = 'Europe')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:774", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the African nations that have a number of residents less than any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT max(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent != \"Asia\" AND population < (SELECT max(population) FROM country WHERE continent != \"Asia\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:775", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which African nations have a smaller number of residents than that of any country in Asia?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Africa\" AND population < (SELECT min(population) FROM country WHERE Continent = \"Asia\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Africa' INTERSECT SELECT min(name) FROM country WHERE continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:776", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which Asian nations have a number of residents that is larger than any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT max(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:777", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the Asian States which have a number of residents larger than that of any country in Africa?", + "gold_sql": "SELECT Name FROM country WHERE Continent = \"Asia\" AND population > (SELECT min(population) FROM country WHERE Continent = \"Africa\")", + "pred_sql": "SELECT name FROM country WHERE continent = 'Asia' AND population > (SELECT max(population) FROM country WHERE continent = 'Africa')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:778", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations for nations that do not speak English?", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT countrycode FROM country WHERE countrycode NOT IN (SELECT countrycode FROM countrylanguage WHERE language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:779", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the State abbreviations for States that do not speak English.", + "gold_sql": "SELECT CountryCode FROM countrylanguage EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT state FROM state WHERE name NOT IN (SELECT T1.name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.Language = \"English\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:780", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of nations where people use languages other than English?", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language != \"English\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:781", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the nation abbreviations for nations in which people speak langauges that are not English.", + "gold_sql": "SELECT DISTINCT CountryCode FROM countrylanguage WHERE LANGUAGE != \"English\"", + "pred_sql": "SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode EXCEPT SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 'N' INTERSECT SELECT T1.countrycode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode WHERE T2.isofficial = 'Y'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:782", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the abbreviations of the nations that do not speak English and whose government types are not Republic?", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" EXCEPT SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"English\" INTERSECT SELECT T1.CountryCode FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.GovernmentForm != \"Republic\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:783", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the abbreviations of States that do not speak English and do not have Republics for governments.", + "gold_sql": "SELECT Code FROM country WHERE GovernmentForm != \"Republic\" EXCEPT SELECT CountryCode FROM countrylanguage WHERE LANGUAGE = \"English\"", + "pred_sql": "SELECT abbreviation FROM country WHERE continent != 'Asia' AND governmentform != 'Republic' AND language != 'English'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:784", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which towns are in European countries where English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 0 INTERSECT SELECT T1.Name FROM city AS T1 JOIN countrylanguage AS T2 ON T1.CountryCode = T2.CountryCode WHERE T2.IsOfficial = 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:785", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of towns in Europe for which English is not the official language?", + "gold_sql": "SELECT DISTINCT T2.Name FROM country AS T1 JOIN city AS T2 ON T2.CountryCode = T1.Code WHERE T1.Continent = 'Europe' AND T1.Name NOT IN (SELECT T3.Name FROM country AS T3 JOIN countrylanguage AS T4 ON T3.Code = T4.CountryCode WHERE T4.IsOfficial = 'T' AND T4.Language = 'English')", + "pred_sql": "SELECT T1.Name FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code JOIN countrylanguage AS T3 ON T2.Code = T3.CountryCode WHERE T3.IsOfficial = 0 AND T2.Name = \"Europe\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:786", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Whic`h unique towns are in Asian States where Chinese is the official language?", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.name = 'Asia' AND T3.Language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:787", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the different names of towns that are in Asia and for which Chinese is the official language.", + "gold_sql": "SELECT DISTINCT T3.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode JOIN city AS T3 ON T1.Code = T3.CountryCode WHERE T2.IsOfficial = 'T' AND T2.Language = 'Chinese' AND T1.Continent = \"Asia\"", + "pred_sql": "SELECT DISTINCT T1.name FROM city AS T1 JOIN country AS T2 ON T1.countrycode = T2.code JOIN countrylanguage AS T3 ON T2.code = T3.CountryCode WHERE T3.IsOfficial = 1 AND T2.name = 'Asia' AND T3.Language = 'Chinese'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:788", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the name, founded year, and territory of the country with the smallest number of residents?", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , territory FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:789", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, year of founded, and territory of the country that has the lowest number of people.", + "gold_sql": "SELECT Name , SurfaceArea , IndepYear FROM country ORDER BY Population LIMIT 1", + "pred_sql": "SELECT name , independyear , continent FROM country ORDER BY population ASC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:790", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the number of residents, name and leader of the country with the largest area?", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , t1.headofstate , t1.population FROM country AS t1 JOIN city AS t2 ON t1.code = t2.countrycode WHERE t1.name = (SELECT name FROM country ORDER BY surfacearea DESC LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:791", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the name, number of residents, and leader of country for the country that has the largest territory.", + "gold_sql": "SELECT Name , population , HeadOfState FROM country ORDER BY SurfaceArea DESC LIMIT 1", + "pred_sql": "SELECT t1.name , COUNT(*) , t1.headofstate FROM country AS t1 JOIN city AS t2 ON t1.code = t2.code GROUP BY t1.name ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:792", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the nation name and the numbers of languages spoken for each country that speaks at least 3 languages.", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.Name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Code HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:793", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of nations that speak more than 2 languages, as well as how many languages they speak?", + "gold_sql": "SELECT COUNT(T2.Language) , T1.Name FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T1.Name HAVING COUNT(*) > 2", + "pred_sql": "SELECT T1.name , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.countrycode GROUP BY T2.countrycode HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:794", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the number of towns in each district whose number of residents is greater than the average population of towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT count(*) , district FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:795", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "How many towns in each district have a population that is above the average number of residents across all towns?", + "gold_sql": "SELECT count(*) , District FROM city WHERE Population > (SELECT avg(Population) FROM city) GROUP BY District", + "pred_sql": "SELECT district , count(*) FROM city WHERE population > (SELECT avg(population) FROM city) GROUP BY district", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:796", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the government type name and total number of residents for each government type whose average lifespan is longer than 72.", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT t1.name , count(*) , avg(t2.lifeexpectancy) FROM country AS t1 JOIN country AS t2 ON t1.code = t2.code WHERE t2.lifeexpectancy > 72 GROUP BY t1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:797", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different government types and what is the total number of residents of each for government types that have an average lifespan greater than 72?", + "gold_sql": "SELECT sum(Population) , GovernmentForm FROM country GROUP BY GovernmentForm HAVING avg(LifeExpectancy) > 72", + "pred_sql": "SELECT governmentform , sum(population) FROM country ORDER BY avg(_lifeexpectancy) > 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:798", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Find the average lifespan and total number of people for each continent where the average lifespan is shorter than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT avg(lifeexpectancy) , sum(population) FROM country WHERE avg(lifeexpectancy) < 72", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:799", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the different continents and the total number of people and average lifespan corresponding to each, for continents that have an average lifespan less than 72?", + "gold_sql": "SELECT sum(Population) , avg(LifeExpectancy) , Continent FROM country GROUP BY Continent HAVING avg(LifeExpectancy) < 72", + "pred_sql": "SELECT T1.Continent , sum(T2.Population) , avg(T2.lifeexpectancy) FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.Code WHERE T1.lifeexpectancy < 72 GROUP BY T1.Continent", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:800", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names and areas of States with the top 5 largest territory?", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , surfacearea FROM country ORDER BY surfacearea DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:801", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names and territory of the 5 largest countries.", + "gold_sql": "SELECT Name , SurfaceArea FROM country ORDER BY SurfaceArea DESC LIMIT 5", + "pred_sql": "SELECT name , region FROM country ORDER BY population DESC LIMIT 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:802", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are names of nations with the top 3 largest number of people?", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:803", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 most populated countries.", + "gold_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "pred_sql": "SELECT Name FROM country ORDER BY Population DESC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:804", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the countries with the 3 lowest number of peoples?", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population ASC LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:805", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of the 3 nations with the fewest people.", + "gold_sql": "SELECT Name FROM country ORDER BY Population ASC LIMIT 3", + "pred_sql": "SELECT name FROM country ORDER BY population LIMIT 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:806", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "how many nations are in Asia?", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:807", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations in Asia.", + "gold_sql": "SELECT count(*) FROM country WHERE continent = \"Asia\"", + "pred_sql": "SELECT count(*) FROM country WHERE Continent = 'Asia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:808", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the names of the States that are in the continent of Europe and have a number of people of 80000?", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT T1.Name FROM country AS T1 JOIN city AS T2 ON T1.Code = T2.CountryCode WHERE T1.Continent = \"Europe\" AND T2.Population = 80000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:809", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the names of nations that are in Europe and have a number of people equal to 80000.", + "gold_sql": "SELECT Name FROM country WHERE continent = \"Europe\" AND Population = \"80000\"", + "pred_sql": "SELECT name FROM country WHERE population = 80000 AND continent = 'Europe'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:810", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of people and average territory of countries in the continent of North America whose territory is bigger than 3000?", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(T1.Population) , avg(T1.Territory) FROM city AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code WHERE T2.Continent = \"North America\" AND T1.Territory > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:811", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the total number of people and average territory corresponding to countries in North America that have a territory greater than 3000.", + "gold_sql": "SELECT sum(Population) , avg(SurfaceArea) FROM country WHERE Continent = \"North America\" AND SurfaceArea > 3000", + "pred_sql": "SELECT sum(t1.population) , avg(t1.population) FROM city AS t1 JOIN country AS t2 ON t1.countrycode = t2.code WHERE t2.continent = \"North America\" AND t1.population > 3000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:812", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the towns whose number of residents is between 160000 and 900000?", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:813", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the names of towns that have a number of people between 160000 and 900000.", + "gold_sql": "SELECT name FROM city WHERE Population BETWEEN 160000 AND 900000", + "pred_sql": "SELECT name FROM city WHERE population BETWEEN 160000 AND 900000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:814", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Which language is spoken by the largest number of nations?", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.Language FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode GROUP BY T2.Language ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:815", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Give the language that is spoken in the most nations.", + "gold_sql": "SELECT LANGUAGE FROM countrylanguage GROUP BY LANGUAGE ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Language FROM countrylanguage AS T1 JOIN country AS T2 ON T1.CountryCode = T2.Code GROUP BY T1.CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:816", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the language spoken by most people in each State?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.Language , T2.State FROM countrylanguage AS T1 JOIN state AS T2 ON T1.CountryCode = T2.CountryCode GROUP BY T2.State ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:817", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the nation abbreviations of the different nations, and what are the languages spoken by the most people for each?", + "gold_sql": "SELECT LANGUAGE , CountryCode , max(Percentage) FROM countrylanguage GROUP BY CountryCode", + "pred_sql": "SELECT T1.nationcode , T2.Language , count(*) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.code = T2.CountryCode GROUP BY T2.Language ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:818", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What is the total number of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT sum(T1.Percentages) FROM country AS T1 JOIN countrylanguage AS T2 ON T1.Code = T2.CountryCode WHERE T2.Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:819", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Count the number of nations for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT count(*) , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT count(DISTINCT countrycode) FROM countrylanguage WHERE Language = \"Spanish\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:820", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "What are the codes of nations where Spanish is spoken by most people?", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT CountryCode FROM countrylanguage WHERE Language = \"Spanish\" GROUP BY CountryCode ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:821", + "benchmark": "spider_syn", + "split": "test", + "db_id": "world_1", + "question": "Return the codes of States for which Spanish is the predominantly spoken language.", + "gold_sql": "SELECT CountryCode , max(Percentage) FROM countrylanguage WHERE LANGUAGE = \"Spanish\" GROUP BY CountryCode", + "pred_sql": "SELECT T1.code FROM countrylanguage AS T1 JOIN country AS T2 ON T1.countrycode = T2.code WHERE T1.Language = \"Spanish\" GROUP BY T1.countrycode HAVING count(*) = size(T1.countrycode)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:822", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many directors are there?", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:823", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of directors.", + "gold_sql": "SELECT count(*) FROM conductor", + "pred_sql": "SELECT count(*) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:824", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of directors in ascending order of age.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:825", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, ordered by age?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Age ASC", + "pred_sql": "SELECT name FROM conductor ORDER BY age", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:826", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors whose countries are not \"USA\"?", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != \"USA\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:827", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the names of directors that do not have the country \"USA\".", + "gold_sql": "SELECT Name FROM conductor WHERE Nationality != 'USA'", + "pred_sql": "SELECT name FROM conductor WHERE nationality != 'USA'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:828", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprise of ensembles in descending order of years in which they were set up?", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT Record_Company FROM orchestra ORDER BY YEAR_OF_Founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:829", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the record enterprise of ensembles, sorted descending by the years in which they were set up.", + "gold_sql": "SELECT Record_Company FROM orchestra ORDER BY Year_of_Founded DESC", + "pred_sql": "SELECT record_company FROM orchestra ORDER BY YEAR_of_founded DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:830", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the average guest of shows?", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:831", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the average guest across all shows.", + "gold_sql": "SELECT avg(Attendance) FROM SHOW", + "pred_sql": "SELECT avg(Attendance) FROM show", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:832", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the maximum and minimum share of performances whose type is not \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:833", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Return the maximum and minimum shares for performance that do not have the type \"Live final\".", + "gold_sql": "SELECT max(SHARE) , min(SHARE) FROM performance WHERE TYPE != \"Live final\"", + "pred_sql": "SELECT max(Share) , min(Share) FROM performance WHERE TYPE != \"Live final\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:834", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many different countries do directors have?", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:835", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of different countries of directors.", + "gold_sql": "SELECT count(DISTINCT Nationality) FROM conductor", + "pred_sql": "SELECT count(DISTINCT nationality) FROM conductor", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:836", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List names of directors in descending order of time of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor ORDER BY year_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:837", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors, sorted descending by the time they became a director?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC", + "pred_sql": "SELECT name FROM conductor WHERE YEAR_of_work = (SELECT max(year_of_work) FROM conductor) ORDER BY YEAR_of_work DESC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:838", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the name of the director with the most years of as a director.", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor WHERE 性别 = '男' INTERSECT SELECT name FROM conductor WHERE 性别 = '女'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:839", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has worked the greatest number of years?", + "gold_sql": "SELECT Name FROM conductor ORDER BY Year_of_Work DESC LIMIT 1", + "pred_sql": "SELECT name FROM conductor ORDER BY age DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:840", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors and the ensembles they have directed.", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.major_record_format FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:841", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors as well as the corresonding ensembles that they have directed?", + "gold_sql": "SELECT T1.Name , T2.Orchestra FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID", + "pred_sql": "SELECT T1.name , T2.major_record_format FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:842", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the names of directors that have conducted more than one ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:843", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have directed at more than one ensemble?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T2.major_record_format HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:844", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the name of the director that has directed the most number of ensembles.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:845", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the name of the director who has directed the most ensembles?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID GROUP BY T2.Conductor_ID ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id GROUP BY T1.name ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:846", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the name of the director that has directed ensembles set up after 2008.", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:847", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the names of directors who have conducted ensembles set up after the year 2008?", + "gold_sql": "SELECT T1.Name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.Conductor_ID = T2.Conductor_ID WHERE Year_of_Founded > 2008", + "pred_sql": "SELECT T1.name FROM conductor AS T1 JOIN orchestra AS T2 ON T1.conductor_id = T2.conductor_id WHERE T2.year_of_founded > 2008", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:848", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the different record enterprise and the corresponding number of ensembles.", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:849", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "How many ensembles does each enterprise manage?", + "gold_sql": "SELECT Record_Company , COUNT(*) FROM orchestra GROUP BY Record_Company", + "pred_sql": "SELECT count(*) , T1.result FROM show AS T1 JOIN orchestra AS T2 ON T1.orchestra_id = T2.orchestra_id JOIN performance AS T3 ON T2.performance_id = T3.performance_id WHERE T2.major_record_format = \"Symphony\" GROUP BY T1.result", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:850", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Please show the record type of ensembles in ascending order of count.", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT T1.record_type FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T2.orchestra_id ORDER BY count(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:851", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the major record formats of ensembles, sorted by their frequency?", + "gold_sql": "SELECT Major_Record_Format FROM orchestra GROUP BY Major_Record_Format ORDER BY COUNT(*) ASC", + "pred_sql": "SELECT major_record_format FROM orchestra GROUP BY major_record_format ORDER BY COUNT(*) ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:852", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the record enterprise shared by the most number of ensembles.", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM performance GROUP BY record_company ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:853", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What is the record enterprise used by the greatest number of ensembles?", + "gold_sql": "SELECT Record_Company FROM orchestra GROUP BY Record_Company ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT record_company FROM orchestra GROUP BY record_company ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:854", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "List the names of ensembles that have no performance.", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:855", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the ensembles that do not have any performance?", + "gold_sql": "SELECT Orchestra FROM orchestra WHERE Orchestra_ID NOT IN (SELECT Orchestra_ID FROM performance)", + "pred_sql": "SELECT orchestra FROM orchestra WHERE orchestra_id NOT IN (SELECT orchestra_id FROM performance)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:856", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the record enterprises shared by ensembles founded before 2003 and after 2003.", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:857", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are the record enterprises that are used by both ensembles founded before 2003 and those founded after 2003?", + "gold_sql": "SELECT Record_Company FROM orchestra WHERE Year_of_Founded < 2003 INTERSECT SELECT Record_Company FROM orchestra WHERE Year_of_Founded > 2003", + "pred_sql": "SELECT record_company FROM orchestra WHERE year_of_founded < 2003 INTERSECT SELECT record_company FROM orchestra WHERE year_of_founded > 2003", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:858", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Find the number of ensembles whose record type is \"CD\" or \"DVD\".", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:859", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Count the number of ensembles that have CD or DVD as their record type.", + "gold_sql": "SELECT COUNT(*) FROM orchestra WHERE Major_Record_Format = \"CD\" OR Major_Record_Format = \"DVD\"", + "pred_sql": "SELECT count(*) FROM orchestra WHERE record_company = \"CD\" OR record_company = \"DVD\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:860", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "Show the years in which ensembles that have given more than one performance are set up.", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:861", + "benchmark": "spider_syn", + "split": "test", + "db_id": "orchestra", + "question": "What are years of seting up for ensembles that have had more than a single performance?", + "gold_sql": "SELECT Year_of_Founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.Orchestra_ID = T2.Orchestra_ID GROUP BY T2.Orchestra_ID HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.year_of_founded FROM orchestra AS T1 JOIN performance AS T2 ON T1.orchestra_id = T2.orchestra_id GROUP BY T1.orchestra_id HAVING count(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:862", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there?", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:863", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students.", + "gold_sql": "SELECT count(*) FROM Highschooler", + "pred_sql": "SELECT count(*) FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:864", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names and grades of each student.", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:865", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names and grades for each student?", + "gold_sql": "SELECT name , grade FROM Highschooler", + "pred_sql": "SELECT name , grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:866", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show all the grades of the students.", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:867", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the grade of each student?", + "gold_sql": "SELECT grade FROM Highschooler", + "pred_sql": "SELECT DISTINCT grade FROM highschooler", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:868", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What grade is Kyle in?", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:869", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade for the student named Kyle.", + "gold_sql": "SELECT grade FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT grade FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:870", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all students in grade 10.", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:871", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of all students in grade 10?", + "gold_sql": "SELECT name FROM Highschooler WHERE grade = 10", + "pred_sql": "SELECT name FROM highschooler WHERE grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:872", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ID of the student named Kyle.", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:873", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is Kyle's id?", + "gold_sql": "SELECT ID FROM Highschooler WHERE name = \"Kyle\"", + "pred_sql": "SELECT id FROM highschooler WHERE name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:874", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are there in grade 9 or 10?", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:875", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of students in grades 9 or 10.", + "gold_sql": "SELECT count(*) FROM Highschooler WHERE grade = 9 OR grade = 10", + "pred_sql": "SELECT count(*) FROM highschooler WHERE grade = 9 OR grade = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:876", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the number of students for each grade.", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:877", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many students are in each grade?", + "gold_sql": "SELECT grade , count(*) FROM Highschooler GROUP BY grade", + "pred_sql": "SELECT count(*) , grade FROM highschooler GROUP BY grade", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:878", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grade has the most students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:879", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the grade that has the greatest number of students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:880", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show me all grades that have at least 4 students.", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT DISTINCT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:881", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Which grades have 4 or more students?", + "gold_sql": "SELECT grade FROM Highschooler GROUP BY grade HAVING count(*) >= 4", + "pred_sql": "SELECT grade FROM highschooler GROUP BY grade HAVING count(*) >= 4", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:882", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the student IDs and numbers of friends corresponding to each.", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT T1.student_id , count(*) FROM Friend AS T1 JOIN HIGH SCHOOLER AS T2 ON T1.friend_id = T2.ID GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:883", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does each student have?", + "gold_sql": "SELECT student_id , count(*) FROM Friend GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.id FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T1.id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:884", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students and their corresponding number of friends.", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN FRIEND AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:885", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of the students and how many friends does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:886", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:887", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the name of the student with the most friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:888", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 3 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:889", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 3 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 3", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 3", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:890", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of all of the student Kyle's friends.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.friend_id = 10", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:891", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the names of friends of the student Kyle.", + "gold_sql": "SELECT T3.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id JOIN Highschooler AS T3 ON T1.friend_id = T3.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T2.student_id = 537", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:892", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many friends does the student Kyle have?", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend WHERE student_id = 54321", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:893", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of friends Kyle has.", + "gold_sql": "SELECT count(*) FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM friend AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id WHERE T1.student_id = 1011253", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:894", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show ids of all students who do not have any friends.", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:895", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who do not have friends?", + "gold_sql": "SELECT id FROM Highschooler EXCEPT SELECT student_id FROM Friend", + "pred_sql": "SELECT id FROM highschooler EXCEPT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:896", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show names of all students who do not have any friends.", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:897", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have no friends?", + "gold_sql": "SELECT name FROM Highschooler EXCEPT SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id", + "pred_sql": "SELECT name FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:898", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the ids of students who have friends and are also liked by someone else.", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM likes GROUP BY student_id INTERSECT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:899", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the ids of students who both have friends and are liked?", + "gold_sql": "SELECT student_id FROM Friend INTERSECT SELECT liked_id FROM Likes", + "pred_sql": "SELECT student_id FROM likes INTERSECT SELECT student_id FROM friend", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:900", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show name of all students who have some friends and also are liked by someone else.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id GROUP BY T3.student_id HAVING count(*) >= 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:901", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who both have friends and are liked?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id INTERSECT SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.liked_id = T2.id", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id JOIN friend AS T3 ON T3.student_id = T2.student_id WHERE T3.friend_id != \"null\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:902", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Count the number of likes for each student id.", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT count(*) , T1.id FROM likes AS T1 JOIN highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:903", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many likes correspond to each student id?", + "gold_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "pred_sql": "SELECT student_id , count(*) FROM Likes GROUP BY student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:904", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have likes, and numbers of likes for each.", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT T1.name , count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:905", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have likes, and how many likes does each have?", + "gold_sql": "SELECT T2.name , count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id", + "pred_sql": "SELECT count(*) , T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T1.name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:906", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the name of the student who has the greatest number of likes?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:907", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Give the name of the student with the most likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:908", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have at least 2 likes.", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:909", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have 2 or more interests?", + "gold_sql": "SELECT T2.name FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:910", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Show the names of students who have a grade higher than 5 and have at least 2 friends.", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id WHERE T1.grade > 5 GROUP BY T2.student_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:911", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What are the names of students who have a grade of over 5 and have 2 or more friends?", + "gold_sql": "SELECT T2.name FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.grade > 5 GROUP BY T1.student_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING count(*) > 2 INTERSECT SELECT T1.name FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id HAVING T1.grade > 5", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:912", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "How many interests does Kyle have?", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM likes WHERE liked_id IN (SELECT id FROM highschooler WHERE name = 'Kyle')", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:913", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Return the number of interests that the student named Kyle has.", + "gold_sql": "SELECT count(*) FROM Likes AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id WHERE T2.name = \"Kyle\"", + "pred_sql": "SELECT count(*) FROM highschooler AS T1 JOIN likes AS T2 ON T1.id = T2.student_id WHERE T1.name = 'Kyle'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:914", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the average grade of all students who have some friends.", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM highschooler AS T1 JOIN friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:915", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the average grade of students who have friends?", + "gold_sql": "SELECT avg(grade) FROM Highschooler WHERE id IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT avg(T1.grade) FROM Highschooler AS T1 JOIN Friend AS T2 ON T1.id = T2.student_id GROUP BY T2.student_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:916", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "Find the minimum grade of students who have no friends.", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:917", + "benchmark": "spider_syn", + "split": "test", + "db_id": "network_1", + "question": "What is the lowest grade of students who do not have any friends?", + "gold_sql": "SELECT min(grade) FROM Highschooler WHERE id NOT IN (SELECT T1.student_id FROM Friend AS T1 JOIN Highschooler AS T2 ON T1.student_id = T2.id)", + "pred_sql": "SELECT min(grade) FROM highschooler WHERE id NOT IN (SELECT student_id FROM friend)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:918", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which states have both guardians and veterinarians living there?", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM Professionals WHERE role_code = \"guardian\" INTERSECT SELECT state FROM Professionals WHERE role_code = \"veterinarian\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:919", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the states where both guardians and veterinarians live.", + "gold_sql": "SELECT state FROM Owners INTERSECT SELECT state FROM Professionals", + "pred_sql": "SELECT state FROM professionals WHERE role_code = 'guardian' INTERSECT SELECT state FROM professionals WHERE role_code = 'veterinary'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:920", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of the dogs who have gone through any medical care?", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T1.age) FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:921", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the average age of the dogs who went through health care.", + "gold_sql": "SELECT avg(age) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT avg(T2.age) FROM treatments AS T1 JOIN dogs AS T2 ON T1.dog_id = T2.dog_id WHERE T1.date_of_treatment = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:922", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in the state of Indiana or have done more than 2 medical cares? List his or her id, family name and cell phone.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name , T1.cell_number FROM owners AS T1 JOIN Professionals AS T2 ON T1.owner_id = T2.professional_id WHERE T1.state = \"indiana\" OR count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:923", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id, last name and cell phone of the veterinarians who live in the state of Indiana or have performed more than two health-cares.", + "gold_sql": "SELECT professional_id , last_name , cell_number FROM Professionals WHERE state = 'Indiana' UNION SELECT T1.professional_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) > 2", + "pred_sql": "SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Indiana\" UNION SELECT T1.owner_id , T1.last_name , T1.cell_number FROM Professionals AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T2.state = \"Illinois\" GROUP BY T1.owner_id HAVING count(*) > 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:924", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs have not cost their guardian more than 1000 for health-care? List the dog names.", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT name FROM dogs WHERE dog_id NOT IN (SELECT dog_id FROM treatments WHERE cost_of_treatment > 1000)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:925", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the names of the dogs for which the guardian spent more than 1000 for health-care?", + "gold_sql": "SELECT name FROM Dogs WHERE dog_id NOT IN( SELECT dog_id FROM Treatments GROUP BY dog_id HAVING sum(cost_of_treatment) > 1000 )", + "pred_sql": "SELECT T1.name FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.cost_of_treatment > 1000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:926", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which first names are used for veterinarians or guardians but are not used as dog names?", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"Veterinarian\" EXCEPT SELECT first_name FROM Professionals WHERE role_code = \"Guardian\" INTERSECT SELECT first_name FROM Professionals WHERE role_code = \"Dog Name\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:927", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the first names that are used for veterinarians or guardians but are not used as dog names.", + "gold_sql": "SELECT first_name FROM Professionals UNION SELECT first_name FROM Owners EXCEPT SELECT name FROM Dogs", + "pred_sql": "SELECT first_name FROM Professionals WHERE role_code = \"Veterinarians\" EXCEPT SELECT first_name FROM Dogs", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:928", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarian did not operate any medical care on dogs? List the veterinarian's id, role and email.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"Medical Care\" EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = \"Dogs\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:929", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the id, role and email of the veterinarians who did not perform any health-care on dogs.", + "gold_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT professional_id , role_code , email_address FROM Professionals EXCEPT SELECT T1.professional_id , T1.role_code , T1.email_address FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:930", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which people owns the most dogs? List the people id, given name and family name.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.first_name , T2.last_name , T1.owner_id FROM Dogs AS T1 JOIN OWNERS AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:931", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the people id, given name and family name of the guardian who has the most dogs.", + "gold_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM Dogs AS T1 JOIN Owners AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:932", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two medical cares? List the veterinarian's id, role, and given name.", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:933", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the id, role, and given name of the veterinarians who have performed two or more health-cares?", + "gold_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.role_code , T1.first_name FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:934", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the name of the breed with the most puppies?", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:935", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which breed do the most puppies have? Give me the breed name.", + "gold_sql": "SELECT T1.breed_name FROM Breeds AS T1 JOIN Dogs AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_name ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T2.breed_name FROM dogs AS T1 JOIN breeds AS T2 ON T1.breed_code = T2.breed_code GROUP BY T1.breed_code ORDER BY count(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:936", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid for the most health cares on his or her dogs? List the guardian id and family name.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.first_name , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id WHERE T3.cost_of_treatment = (SELECT max(cost_of_treatment) FROM Treatments WHERE dog_id IN (SELECT dog_id FROM Dogs WHERE gender = 'M') )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:937", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the guardian id and family name of the guardian who spent the most on treatments of his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY count(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T2.first_name , T2.last_name FROM owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:938", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the describing details of the health-care type that costs the least money in total?", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.treatment_type_description FROM Treatment_Types AS T1 JOIN charges AS T2 ON T1.dog_id = T2.dog_id WHERE T2.charge_type = 'healthcare' GROUP BY T1.treatment_type_code ORDER BY sum(T2.charge_amount) ASC LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:939", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Give me the describing details of the health-care whose total cost is the lowest.", + "gold_sql": "SELECT T1.treatment_type_description FROM Treatment_types AS T1 JOIN Treatments AS T2 ON T1.treatment_type_code = T2.treatment_type_code GROUP BY T1.treatment_type_code ORDER BY sum(cost_of_treatment) ASC LIMIT 1", + "pred_sql": "SELECT T1.breed_name FROM breeds AS T1 JOIN treatment_types AS T2 ON T1.breed_code = T2.treatment_type_code JOIN treatments AS T3 ON T1.dog_id = T3.dog_id WHERE T3.cost_of_treatment = (SELECT min(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:940", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardian has paid the largest amount of money in total for their puppies? Show the guardian id and zip code.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:941", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the guardian id and zip code of the guardian who spent the most money in total for his or her puppies.", + "gold_sql": "SELECT T1.owner_id , T1.zip_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id JOIN Treatments AS T3 ON T2.dog_id = T3.dog_id GROUP BY T1.owner_id ORDER BY sum(T3.cost_of_treatment) DESC LIMIT 1", + "pred_sql": "SELECT T1.owner_id , T1.zip_code FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.gender = \"M\" GROUP BY T1.owner_id ORDER BY sum(T3.charge_amount) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:942", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have done at least two types of health-care? List the veterinarian id and cell phone.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:943", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the id and cell phone of the veterinarians who operate two or more types of health-care.", + "gold_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "pred_sql": "SELECT T1.professional_id , T1.cell_number FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.professional_id GROUP BY T1.professional_id HAVING count(*) >= 2", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:944", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the first name and family name of the veterinarians who have done medical care with cost below average?", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM Treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:945", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians have operated a medical care that costs less than the average? Give me theor given names and family names.", + "gold_sql": "SELECT DISTINCT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN Treatments AS T2 on T2.professional_id = T1.professional_id WHERE cost_of_treatment < ( SELECT avg(cost_of_treatment) FROM Treatments )", + "pred_sql": "SELECT T1.first_name , T1.last_name FROM Professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id WHERE T2.cost_of_treatment < (SELECT avg(cost_of_treatment) FROM treatments)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:946", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the date of each medical care, together with the given name of the veterinarian who operated it.", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T3.first_name , T3.last_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id JOIN owners AS T3 ON T2.owner_id = T3.owner_id WHERE T2.role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:947", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the date and the operating veterinarian's given name of each medical care?", + "gold_sql": "SELECT T1.date_of_treatment , T2.first_name FROM Treatments AS T1 JOIN Professionals AS T2 ON T1.professional_id = T2.professional_id", + "pred_sql": "SELECT T1.date_of_treatment , T2.first_name FROM treatments AS T1 JOIN professionals AS T2 ON T1.professional_id = T2.professional_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:948", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the cost of each health-care and the corresponding health-care type describing details.", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT T1.charge_amount , T2.treatment_type_description FROM charges AS T1 JOIN treatment_types AS T2 ON T1.charge_type = T2.treatment_type_code WHERE T1.charge_type = \"Healthcare\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:949", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the cost and health-care type describing content of each health-care?", + "gold_sql": "SELECT T1.cost_of_treatment , T2.treatment_type_description FROM Treatments AS T1 JOIN treatment_types AS T2 ON T1.treatment_type_code = T2.treatment_type_code", + "pred_sql": "SELECT cost_of_treatment , treatment_type_code FROM treatments WHERE treatment_type_code = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:950", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each guardian's first name, last name, and the size of his for her dog.", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T4.size_description FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T2.size_code = T3.size_code JOIN treatments AS T4 ON T4.dog_id = T2.dog_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:951", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's first name, last name, and the size of their dog?", + "gold_sql": "SELECT T1.first_name , T1.last_name , T2.size_code FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name , T3.weight FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id JOIN sizes AS T3 ON T1.size_code = T3.size_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:952", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List pairs of the guardians's given name and the puppies's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:953", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each guardians's given name and their puppies's name?", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id", + "pred_sql": "SELECT T2.first_name , T2.last_name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = 12", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:954", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the names of the puppies of the rarest breed and the health care dates of them.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.breed_name , T2.date_of_treatment FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T1.breed_name = (SELECT breed_name FROM dogs ORDER BY rarest IN (1) LIMIT 1)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:955", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are of the rarest breed? Show their names and medical care dates.", + "gold_sql": "SELECT T1.name , T2.date_of_treatment FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T1.breed_code = ( SELECT breed_code FROM Dogs GROUP BY breed_code ORDER BY count(*) ASC LIMIT 1 )", + "pred_sql": "SELECT T1.name , T4.date_of_treatment FROM dogs AS T1 JOIN treatments AS T2 ON T1.dog_id = T2.dog_id JOIN professionals AS T3 ON T2.professional_id = T3.professional_id JOIN treatment_types AS T4 ON T3.treatment_type_code = T4.treatment_type_code WHERE T4.treatment_type_description = 'Medical Care' ORDER BY T5.breed_name LIMIT 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:956", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which dogs are owned by someone who lives in Virginia? List the guardian's first name and the dog's name.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.first_name , T2.name FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city = \"Virginia\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:957", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the given names of guardians living in Virginia and the names of dogs they own.", + "gold_sql": "SELECT T1.first_name , T2.name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T1.state = 'Virginia'", + "pred_sql": "SELECT T2.name , T3.owner_id FROM owners AS T1 JOIN dogs AS T2 ON T1.owner_id = T2.owner_id JOIN owners AS T3 ON T1.city = T3.city WHERE T1.state = 'Virginia'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:958", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of the puppies who have gone through a medical care?", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Medical Care\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:959", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the arriving and leaving date of the puppies that received a health care.", + "gold_sql": "SELECT DISTINCT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id", + "pred_sql": "SELECT T1.date_arrived , T1.date_departed FROM Dogs AS T1 JOIN Treatments AS T2 ON T1.dog_id = T2.dog_id WHERE T2.treatment_type_code = \"Health\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:960", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the family name of the guardian owning the youngest puppy.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id WHERE T1.age = (SELECT min(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:961", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Who owns the youngest puppy? Give me his or her last name.", + "gold_sql": "SELECT T1.last_name FROM Owners AS T1 JOIN Dogs AS T2 ON T1.owner_id = T2.owner_id WHERE T2.age = ( SELECT max(age) FROM Dogs )", + "pred_sql": "SELECT T2.last_name FROM dogs AS T1 JOIN owners AS T2 ON T1.owner_id = T2.owner_id ORDER BY T1.age LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:962", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the emails of the veterinarians who live in the state of Hawaii or the state of Wisconsin.", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE role_code = 'veterinary' AND state = 'Hawaii' OR state = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:963", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the emails of the veterinarians living in either the state of Hawaii or the state of Wisconsin?", + "gold_sql": "SELECT email_address FROM Professionals WHERE state = 'Hawaii' OR state = 'Wisconsin'", + "pred_sql": "SELECT email_address FROM professionals WHERE role_code = 'veterinary' AND state = 'Hawaii' OR state = 'Wisconsin'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:964", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the arriving and leaving date of all the puppies?", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:965", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the arriving and leaving date for all the puppies.", + "gold_sql": "SELECT date_arrived , date_departed FROM Dogs", + "pred_sql": "SELECT date_arrived , date_departed FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:966", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies went through any health cares?", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = 'health care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:967", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies that went through a health care.", + "gold_sql": "SELECT count(DISTINCT dog_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM treatments AS T JOIN dogs AS D ON T.dog_id = D.dog_id WHERE T.treatment_type_code = \"Healthcare\";", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:968", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians have performed any health care to puppies?", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatments AS T2 ON T1.professional_id = T2.professional_id JOIN dogs AS T3 ON T2.dog_id = T3.dog_id WHERE T3.gender = 'P' AND T2.treatment_type_code = 'health'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:969", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have ever treated puppies.", + "gold_sql": "SELECT count(DISTINCT professional_id) FROM Treatments", + "pred_sql": "SELECT count(*) FROM professionals AS T1 JOIN treatment_types AS T2 ON T1.professional_id = T2.professional_id WHERE T2.treatment_type_code = 'Puppy Care'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:970", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which veterinarians live in a city containing the substring 'West'? List his or her role, street, town and state.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT T2.role_code , T1.street , T1.city , T1.state FROM owners AS T1 JOIN professionals AS T2 ON T1.owner_id = T2.owner_id WHERE T1.city LIKE '%West%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:971", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the role, street, town and state of the veterinarians living in a town that contains the substring 'West'.", + "gold_sql": "SELECT role_code , street , city , state FROM professionals WHERE city LIKE '%West%'", + "pred_sql": "SELECT role_code , street , city , state FROM Professionals WHERE city LIKE \"%West%\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:972", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Which guardians live in the state whose name contains the substring 'North'? List his given name, family name and email.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM owners WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:973", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Return the given name, family name and email of the guardians living in a state whose name contains the substring 'North'.", + "gold_sql": "SELECT first_name , last_name , email_address FROM Owners WHERE state LIKE '%North%'", + "pred_sql": "SELECT first_name , last_name , email_address FROM OWNERS WHERE state LIKE '%North%'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:974", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have an age below the average?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM dogs WHERE age < (SELECT avg(age) FROM dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:975", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Count the number of puppies of an age below the average.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE age < ( SELECT avg(age) FROM Dogs )", + "pred_sql": "SELECT count(*) FROM Dogs WHERE age < (SELECT avg(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:976", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most recent health-care cost?", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT max(t1.charge_amount) FROM charges AS t1 JOIN treatment_types AS t2 ON t1.charge_type = t2.treatment_type_code WHERE t2.treatment_type_description = 'Healthcare' AND t2.treatment_type_code = 'Inpatient'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:977", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Show me the cost of the most recently performed medical care.", + "gold_sql": "SELECT cost_of_treatment FROM Treatments ORDER BY date_of_treatment DESC LIMIT 1", + "pred_sql": "SELECT cost_of_treatment FROM treatments ORDER BY date_of_treatment DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:978", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many puppies have not gone through any medical care?", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id NOT IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM dogs WHERE dog_id NOT IN ( SELECT dog_id FROM treatments )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:979", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the number of puppies that have received any health-care.", + "gold_sql": "SELECT count(*) FROM Dogs WHERE dog_id IN ( SELECT dog_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = 'Healthcare'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:980", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many guardians temporarily do not have any puppies?", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM treatments WHERE treatment_type_code = 'Guardian' EXCEPT SELECT count(*) FROM treatments WHERE treatment_type_code = 'Puppy'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:981", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of guardians who do not own any puppies at this moment.", + "gold_sql": "SELECT count(*) FROM Owners WHERE owner_id NOT IN ( SELECT owner_id FROM Dogs )", + "pred_sql": "SELECT count(*) FROM owners WHERE owner_id NOT IN ( SELECT owner_id FROM dogs WHERE gender = 'Puppy' )", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:982", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How many veterinarians did not operate any treatment on puppies?", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE role_code != 'treatment_provider'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:983", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the number of veterinarians who have not treated any puppies.", + "gold_sql": "SELECT count(*) FROM Professionals WHERE professional_id NOT IN ( SELECT professional_id FROM Treatments )", + "pred_sql": "SELECT count(*) FROM professionals WHERE professional_id NOT IN ( SELECT professional_id FROM treatments WHERE treatment_type_code = \"puppy\")", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:984", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the puppy name, age and weight of the puppies who have been abandoned? 1 stands for yes, and 0 stands for no.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:985", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the puppy name, age and weight of the puppies that were abandoned? Note that 1 stands for yes, and 0 stands for no in the tables.", + "gold_sql": "SELECT name , age , weight FROM Dogs WHERE abandoned_yn = 1", + "pred_sql": "SELECT name , age , weight FROM dogs WHERE abandoned_yn = 1;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:986", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the average age of all the puppies?", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:987", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Compute the average age of all the puppies.", + "gold_sql": "SELECT avg(age) FROM Dogs", + "pred_sql": "SELECT avg(age) FROM Dogs WHERE gender = 'dog' AND breed_code = 'pudding'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:988", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the age of the oldest puppy?", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT max(age) FROM Dogs WHERE gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:989", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Tell me the age of the oldest puppy.", + "gold_sql": "SELECT max(age) FROM Dogs", + "pred_sql": "SELECT age FROM Dogs WHERE age = (SELECT max(age) FROM Dogs)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:990", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does each charge type costs? List both charge type and amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:991", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List each charge type and its amount.", + "gold_sql": "SELECT charge_type , charge_amount FROM Charges", + "pred_sql": "SELECT charge_type , charge_amount FROM Charges;", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:992", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "How much does the most expensive charge type costs?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:993", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What is the charge amount of the most expensive charge type?", + "gold_sql": "SELECT max(charge_amount) FROM Charges", + "pred_sql": "SELECT charge_amount FROM charges ORDER BY charge_amount DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:994", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the email, cell phone and home phone of all the veterinarians.", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM Professionals WHERE role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:995", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are the email, cell phone and home phone of each veterinarian?", + "gold_sql": "SELECT email_address , cell_number , home_phone FROM professionals", + "pred_sql": "SELECT email_address , cell_number , home_phone FROM Professionals WHERE role_code = 'Veterinary';", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:996", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are all the possible breed type and size type combinations?", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:997", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "Find the distinct breed type and size type combinations for puppies.", + "gold_sql": "SELECT DISTINCT breed_code , size_code FROM dogs", + "pred_sql": "SELECT DISTINCT T1.breed_name , T2.size_description FROM breeds AS T1 JOIN dogs AS T2 ON T1.breed_code = T2.breed_code WHERE T2.age = 3 and T2.gender = 'P'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:998", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "List the given name of all the veterinarians along with the description of the medical care they have done.", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T1.last_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code WHERE T1.role_code = 'Veterinarian'", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:999", + "benchmark": "spider_syn", + "split": "test", + "db_id": "dog_kennels", + "question": "What are each veterinarian's first name and describing details of the health-care they have performed?", + "gold_sql": "SELECT DISTINCT T1.first_name , T3.treatment_type_description FROM professionals AS T1 JOIN Treatments AS T2 ON T1.professional_id = T2.professional_id JOIN Treatment_types AS T3 ON T2.treatment_type_code = T3.treatment_type_code", + "pred_sql": "SELECT T1.first_name , T2.treatment_type_description FROM Professionals AS T1 JOIN Treatment_Types AS T2 ON T1.professional_id = T2.treatment_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1000", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "How many vocalists are there?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1001", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the count of musicians?", + "gold_sql": "SELECT count(*) FROM singer", + "pred_sql": "SELECT count(*) FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1002", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists in ascending order of net worth.", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1003", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of musicians ordered by ascending net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions ASC", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1004", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth year and country of vocalists?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1005", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the birth years and country of the musicians?", + "gold_sql": "SELECT Birth_Year , Citizenship FROM singer", + "pred_sql": "SELECT Birth_Year , Citizenship FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1006", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of vocalists whose citizenship is not \"France\".", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1007", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians who are not French citizens?", + "gold_sql": "SELECT Name FROM singer WHERE Citizenship != \"France\"", + "pred_sql": "SELECT Name FROM singer WHERE Citizenship != \"French\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1008", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the name of vocalists whose birth year is either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1009", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the musicians whose birth years are either 1948 or 1949?", + "gold_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "pred_sql": "SELECT Name FROM singer WHERE Birth_Year = 1948 OR Birth_Year = 1949", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1010", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist with the largest net worth?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1011", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of the vocalist who is worth the most?", + "gold_sql": "SELECT Name FROM singer ORDER BY Net_Worth_Millions DESC LIMIT 1", + "pred_sql": "SELECT name FROM singer ORDER BY net_works_millions DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1012", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different citizenship of vocalists and the number of vocalists of each country.", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1013", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, how many musicians are from that country?", + "gold_sql": "SELECT Citizenship , COUNT(*) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT Country , COUNT(*) FROM singer GROUP BY Country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1014", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Please show the most common country of vocalists.", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT T1.Citizenship FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1015", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the msot common vocalist country?", + "gold_sql": "SELECT Citizenship FROM singer GROUP BY Citizenship ORDER BY COUNT(*) DESC LIMIT 1", + "pred_sql": "SELECT country FROM singer INTERSECT SELECT country FROM singer", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1016", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show different country and the maximum net worth of musicians of each country.", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT citizenship , max(net_workmillions) FROM singer GROUP BY citizenship", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1017", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each country, what is the maximum net worth?", + "gold_sql": "SELECT Citizenship , max(Net_Worth_Millions) FROM singer GROUP BY Citizenship", + "pred_sql": "SELECT country , max(net_worth_millions) FROM singer GROUP BY country", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1018", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show names of songs and names of musicians.", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T1.Title , T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1019", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the song names and vocalist names?", + "gold_sql": "SELECT T2.Title , T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID", + "pred_sql": "SELECT T2.Title , T3.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID JOIN song AS T3 ON T2.Singer_ID = T3.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1020", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show distinct names of musicians that have songs with sales more than 300000.", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1021", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "what are the different names of the vocalists that have sales more than 300000?", + "gold_sql": "SELECT DISTINCT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T2.Sales > 300000", + "pred_sql": "SELECT DISTINCT T2.Name FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID WHERE T1.Sales > 300000", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1022", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians that have more than one song.", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1023", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the names of the vocalists that have more than one songs?", + "gold_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "pred_sql": "SELECT T1.Name FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name HAVING COUNT(*) > 1", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1024", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the names of musicians and the total sales of their songs.", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , avg(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Singer_ID", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1025", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "For each vocalist name, what is the total sales for their songs?", + "gold_sql": "SELECT T1.Name , sum(T2.Sales) FROM singer AS T1 JOIN song AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T1.Name", + "pred_sql": "SELECT T2.Name , SUM(T1.Sales) FROM song AS T1 JOIN singer AS T2 ON T1.Singer_ID = T2.Singer_ID GROUP BY T2.Name", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1026", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "List the name of musicians that do not have any song.", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1027", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What is the name of every vocalist that does not have any song?", + "gold_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "pred_sql": "SELECT Name FROM singer WHERE Singer_ID NOT IN (SELECT Singer_ID FROM song)", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1028", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "Show the citizenship shared by musicians with birth year before 1945 and after 1955.", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1029", + "benchmark": "spider_syn", + "split": "test", + "db_id": "singer", + "question": "What are the country that are shared by musicians with a birth year before 1945 and after 1955?", + "gold_sql": "SELECT Citizenship FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Citizenship FROM singer WHERE Birth_Year > 1955", + "pred_sql": "SELECT Country FROM singer WHERE Birth_Year < 1945 INTERSECT SELECT Country FROM singer WHERE Birth_Year > 1955", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1030", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "How many available characteristic are there in total?", + "gold_sql": "SELECT count(*) FROM Other_Available_Features", + "pred_sql": "SELECT count(*) FROM Other_Available_Features", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1031", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What is the characteristic type of feature AirCon?", + "gold_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "pred_sql": "SELECT T2.feature_type_name FROM Other_Available_Features AS T1 JOIN Ref_Feature_Types AS T2 ON T1.feature_type_code = T2.feature_type_code WHERE T1.feature_name = \"AirCon\"", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1032", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "Show the property type descriptions of properties belonging to that code.", + "gold_sql": "SELECT T2.property_type_description FROM Properties AS T1 JOIN Ref_Property_Types AS T2 ON T1.property_type_code = T2.property_type_code GROUP BY T1.property_type_code", + "pred_sql": "SELECT T2.property_type_description FROM properties AS T1 JOIN ref_property_types AS T2 ON T1.property_type_code = T2.property_type_code", + "success": true, + "error": null + }, + { + "sample_id": "spider_syn:test:1033", + "benchmark": "spider_syn", + "split": "test", + "db_id": "real_estate_properties", + "question": "What are the names of properties that are either houses or apartments with more than 1 room?", + "gold_sql": "SELECT property_name FROM Properties WHERE property_type_code = \"House\" UNION SELECT property_name FROM Properties WHERE property_type_code = \"Apartment\" AND room_count > 1", + "pred_sql": "SELECT T1.property_name FROM properties AS T1 JOIN ref_property_ttypes AS T2 ON T1.property_type_code = T2.property_type_code WHERE T2.property_type_description = 'House' UNION SELECT T1.property_name FROM properties AS T1 JOIN ref_property_ttypes AS T2 ON T1.property_type_code = T2.property_type_code WHERE T2.property_type_description = 'Apartment' AND T1.room_count > 1", + "success": true, + "error": null + } +] \ No newline at end of file